Virtual scene interaction data processing method and apparatus, and electronic device, computer program product and computer-readable storage medium
By adjusting the position of virtual objects frame by frame in the virtual scene, the problem of stiff movements during the interaction between virtual objects and interactive objects in the prior art is solved, and a more natural and smooth interaction effect is achieved, improving the picture fluency and ease of use of interactive control.
Patent Information
- Application Number
- PCT/CN2024/100634
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2023-09-28
- Filing Date
- 2024-06-21
- Publication Date
- 2025-04-03
AI Technical Summary
The prior art has the rigid movements during the interaction between virtual objects and interactive objects in virtual scenes, which affects the smoothness of screen display.
By displaying virtual objects and interactive objects in the virtual scene, obtaining the current pose in response to interaction conditions, determining the ratio of the pose difference value to the transition frame number as the pose adjustment value, and adjusting the pose of the virtual object frame by frame, so that it naturally transitions to the reference pose.
It realizes the natural and smooth transition of interactive actions in virtual scenes, improves the smoothness of terminal device screen display, simplifies the triggering process of interactive controls, and reduces resource waste.
Smart Images

Figure CN2024100634_03042025_PF_FP_ABST
Abstract
Description
Virtual scene interactive data processing method, device, electronic device, computer program product and computer-readable storage medium
[0001] CROSS-REFERENCE TO RELATED APPLICATIONS
[0002] This application is based on the Chinese patent application with application number 202311276899.5 and application date September 28, 2023, and claims the priority of the Chinese patent application. The content of the Chinese patent application is hereby introduced into this application as a reference. Technical Field
[0003] The present invention relates to computer human-computer interaction technology, and in particular to a virtual scene interaction data processing method, device, electronic device, computer program product and computer-readable storage medium. Background Art
[0004] With the development of computer technology, electronic devices can realize richer and more vivid virtual scenes. A virtual scene is a digital scene created by a computer through digital communication technology. Users (or players) can experience a completely virtualized experience of vision and hearing in the virtual scene (such as virtual reality) or a partially virtualized experience (such as augmented reality). At the same time, they can control objects in the virtual scene to interact and obtain feedback.
[0005] When it is necessary to control a virtual object to move from its current position to another position in a virtual scene, related technologies usually use a method of controlling the virtual object to move directly. For example, controlling the virtual object to forcibly move from its current position to another position causes the virtual object to move stiffly, affecting the smoothness of the terminal device screen display.
[0006] Summary of the Invention
[0007] The embodiments of the present application provide a method, device, electronic device, computer program product, and computer-readable storage medium for processing virtual scene interactive data, which can enable a natural and smooth transition of interactive actions in a virtual scene.
[0008] The technical solution of the embodiment of the present application is implemented as follows:
[0009] An embodiment of the present application provides a method for processing virtual scene interaction data, the method being executed by an electronic device, the method comprising:
[0010] Displaying virtual objects and interactive objects in a virtual scene;
[0011] In response to the virtual object satisfying an interaction condition between the virtual object and the interactable object at a first moment, obtaining a current pose of the virtual object at the first moment;
[0012] Determining a pose difference between the current pose and a reference pose, wherein the reference pose is an initial pose of the virtual object in interacting with the interactable object;
[0013] Determining a ratio of the posture difference to a transition frame number as a posture adjustment value, wherein the transition frame number is the number of image frames between the first moment and the second moment;
[0014] The virtual object is controlled to implement the posture adjustment value in each image frame from the first moment until the second moment.
[0015] The present invention provides a virtual scene interactive data processing device, comprising:
[0016] a display module configured to display virtual objects and interactive objects in a virtual scene;
[0017] an acquisition module, configured to, in response to the virtual object satisfying an interaction condition between the virtual object and the interactable object at a first moment, acquire a current posture of the virtual object at the first moment;
[0018] a first determining module configured to determine a posture difference between the current posture and a reference posture, wherein the reference posture is an initial posture of the virtual object in interacting with the interactable object;
[0019] a second determining module configured to determine a ratio of the posture difference to a transition frame number as a posture adjustment value, wherein the transition frame number is the number of image frames between the first moment and the second moment;
[0020] The data adjustment module is configured to control the virtual object to implement the posture adjustment value in each image frame from the first moment to the second moment.
[0021] An embodiment of the present application provides an electronic device, the electronic device comprising:
[0022] a memory for storing computer-executable instructions;
[0023] The processor is used to implement the virtual scene interactive data processing method provided in the embodiment of the present application when executing the computer executable instructions stored in the memory.
[0024] An embodiment of the present application provides a computer-readable storage medium storing a computer program or computer-executable instructions, which is used to implement the virtual scene interactive data processing method provided in the embodiment of the present application when executed by a processor.
[0025] An embodiment of the present application provides a computer program product, including a computer program or computer executable instructions. When the computer program or computer executable instructions are executed by a processor, the virtual scene interactive data processing method provided in the embodiment of the present application is implemented.
[0026] The embodiments of the present application have the following beneficial effects:
[0027] By converting the current posture of the virtual object at the first moment to the reference posture at the second moment frame by frame, the interaction process between the virtual object and the interactive object becomes more natural, improving the smoothness of the terminal device screen display. In addition, the virtual object is adjusted to the reference posture, making it easier to trigger the interactive control, avoiding multiple triggering and reducing resource waste. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] FIG1A is a schematic diagram of a first application mode of a virtual scene interactive data processing method provided by an embodiment of the present application;
[0029] FIG1B is a schematic diagram of a second application mode of the virtual scene interactive data processing method provided in an embodiment of the present application;
[0030] FIG2 is a schematic diagram of the structure of a terminal device 400 provided in an embodiment of the present application;
[0031] FIG3A is a schematic diagram of a first flow chart of a method for processing virtual scene interaction data provided by an embodiment of the present application;
[0032] FIG3B is a second flow chart of the virtual scene interaction data processing method provided in an embodiment of the present application;
[0033] FIG3C is a schematic diagram of a third flow chart of the virtual scene interaction data processing method provided in an embodiment of the present application;
[0034] FIG3D is a schematic diagram of a fourth flow chart of the virtual scene interaction data processing method provided in an embodiment of the present application;
[0035] FIG3E is a fifth flow chart of the method for processing virtual scene interaction data provided in an embodiment of the present application;
[0036] FIG3F is a sixth flow chart of the virtual scene interaction data processing method provided in an embodiment of the present application;
[0037] FIG3G is a seventh flow chart of the virtual scene interaction data processing method provided in an embodiment of the present application;
[0038] 3H is a schematic diagram of an eighth flow chart of the virtual scene interaction data processing method provided in an embodiment of the present application;
[0039] FIG4A is a first schematic diagram of an application scenario of the virtual scene interactive data processing method provided in an embodiment of the present application;
[0040] FIG4B is a second schematic diagram of an application scenario of the virtual scene interactive data processing method provided in an embodiment of the present application;
[0041] FIG4C is a third schematic diagram of an application scenario of the virtual scene interactive data processing method provided in an embodiment of the present application;
[0042] FIG4D is a fourth schematic diagram of an application scenario of the virtual scene interactive data processing method provided in an embodiment of the present application;
[0043] FIG4E is a fifth schematic diagram of an application scenario of the virtual scene interactive data processing method provided in an embodiment of the present application;
[0044] FIG5 is a flow chart of an application scenario of a virtual scene interactive data processing method provided in an embodiment of the present application;
[0045] FIG6 is a schematic diagram of the posture of a virtual object in a world coordinate system provided by this embodiment. DETAILED DESCRIPTION
[0046] In order to make the purpose, technical solutions and advantages of this application clearer, the application will be further described in detail below with reference to the accompanying drawings. The described embodiments should not be regarded as limiting this application. All other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.
[0047] In the following description, reference is made to “some embodiments”, which describes a subset of all possible embodiments, but it will be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.
[0048] In the following description, the terms "first\second\third" involved are merely used to distinguish similar objects and do not represent a specific ordering of the objects. It can be understood that "first\second\third" can be interchanged with a specific order or sequence where permitted, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein.
[0049] The relevant data collection and processing in the embodiments of this application should be strictly in accordance with the requirements of relevant laws and regulations when applied in examples, and the informed consent or separate consent of the personal information subject should be obtained. Subsequent data use and processing should be carried out within the scope of authorization of laws and regulations and the personal information subject.
[0050] Unless otherwise defined, all technical and scientific terms used in the embodiments of the present application have the same meanings as those commonly understood by those skilled in the art. The terms used in the embodiments of the present application are only for the purpose of describing the embodiments of the present application and are not intended to limit the present application.
[0051] Before further describing the embodiments of the present application in detail, the nouns and terms involved in the embodiments of the present application are explained. The nouns and terms involved in the embodiments of the present application are subject to the following interpretations.
[0052] 1) A virtual scene is a scene that is displayed (or provided) when an application is running on a terminal device and is different from the real world. The virtual scene can be a simulation of the real world, a semi-simulation and semi-fictitious virtual environment, or a purely fictitious virtual environment. The virtual scene can be any of a two-dimensional virtual scene, a 2.5-dimensional virtual scene, or a three-dimensional virtual scene. The embodiments of the present application do not limit the dimensions of the virtual scene. For example, the virtual scene may include the sky, land, ocean, etc., and the land may include environmental elements such as deserts and cities. Users can control virtual objects to move in the virtual scene.
[0053] 2) Virtual objects: movable objects within a virtual scene. These movable objects can be virtual people, virtual animals, cartoon characters, and the like. These virtual objects can be virtual avatars representing users within the virtual scene, or they can be user characters controlled through client-side operations. A virtual scene can include multiple virtual objects, each with its own unique shape and volume, occupying a portion of the space within the virtual scene.
[0054] 3) Interactive objects, also known as non-player characters (NPCs), are the various interactive people and objects in the virtual scene that are not controlled by real players. For example, they can be artificial intelligence (AI) trained to play in the virtual scene. Interactive objects can include virtual people, virtual animals, and anime characters, such as people, animals, plants, oil drums, walls, and rocks displayed in the virtual scene. The number of interactive objects in the virtual scene can be pre-set or dynamically determined during the virtual scene's operation.
[0055] 4) Pose: This describes the position, posture, and orientation of a virtual object in the world coordinate system. Position represents the coordinates of the virtual object's center or reference point in 3D space, typically represented by three real numbers. Pose represents the physical state of the virtual object in the virtual scene, such as holding a prop or being empty-handed. Orientation represents the direction the virtual object faces in 3D space and can be represented by rotation matrices, Euler angles, or quaternions.
[0056] 5) World Coordinate System. In a virtual scene, the world coordinate system is used to describe the position and orientation of objects within the virtual scene. Its main functions are: displaying the three-dimensional coordinates of the target object and determining the target object's position based on the origin. The origin in the world coordinate system can be the center point of the virtual scene. The horizontal coordinate axis (x-axis) can be a line passing through the origin and parallel to the boundary line of the virtual scene. The vertical coordinate axis (y-axis) is a line in the same horizontal plane as the x-axis, passing through the origin and perpendicular to the horizontal coordinate axis. The vertical coordinate axis is a line passing through the origin and perpendicular to the plane xoy.
[0057] 6) Cloud Gaming: Also known as Gaming on Demand, this involves deploying a game program on a server and running an instance of the game program (referred to as a game instance). The game instance sends the game data generated during operation to the browser page on the user's terminal. The page then calls the browser's media component to decode the game data and renders the real-time game screen based on the decoded results. When the page detects user actions on the game screen, it reports them to the game instance running on the server. Upon receiving the game data generated by the game instance in response to the action, the decoding and rendering process is repeated, presenting the game screen changes based on the user's actions on the page.
[0058] In other words, cloud gaming is an online gaming technology based on cloud computing. Cloud gaming technology enables thin clients with relatively limited graphics and data processing capabilities to run high-quality games. In a cloud gaming scenario, the game is not played on the user terminal (e.g., the player's gaming terminal), but rather on a cloud server. The cloud server renders the game scene into an audio and video stream, which is transmitted to the user terminal over the network. This eliminates the need for powerful graphics and data processing capabilities, requiring only basic streaming media playback capabilities and the ability to receive player input and send it to the cloud server.
[0059] 7) Interaction Conditions: These are the necessary conditions that must be met before a virtual object and an interactive object can interact (e.g., exchange information and interact with each other). For example, an interaction condition may include: the distance between the virtual object and the interactive object at a first moment is less than or equal to a distance threshold, or receiving an operation instruction at a first moment to trigger a control prop, where the control prop is used to control the interactive object to interact with the virtual object.
[0060] In the interactive scheme of virtual scenes in related technologies, the current posture of the virtual object is usually forcibly switched to the reference posture without a transition process, which makes the virtual object's movement stiff and the movement switching process unnatural.
[0061] The applicant has found that the interaction processing method of the related art cannot naturally switch the posture of the virtual object. To address the above problem, the embodiment of the present application provides a virtual scene interaction data processing method that can make the interaction actions in the virtual scene transition naturally and smoothly.
[0062] The embodiments of the present application provide a virtual scene interactive data processing method, device, electronic device, computer-readable storage medium and computer program product, which can make the interactive actions of virtual objects and interactive objects more natural. The following describes an exemplary application of the electronic device provided by the embodiment of the present application. The device provided by the embodiment of the present application can be implemented as various types of terminals such as laptops, tablets, desktop computers, set-top boxes, mobile devices (for example, mobile phones, portable music players, personal digital assistants, dedicated messaging devices, portable gaming devices), smart phones, smart speakers, smart watches, smart TVs, vehicle terminals, aircraft, etc., and can also be implemented as servers. Below, an exemplary application when the electronic device is implemented as a terminal will be described.
[0063] In some embodiments, the virtual scene can be an environment for virtual objects (such as game characters) to interact. For example, it can be an environment for game characters to fight in the virtual scene. By controlling the actions of the game characters, both parties can interact in the virtual scene, allowing users to relieve life stress during the game.
[0064] In one implementation scenario, referring to FIG1A , FIG1A is a schematic diagram of a first application mode of a virtual scene interactive data processing method provided in an embodiment of the present application, which is applicable to some application modes that completely rely on the graphics processing hardware computing power of the terminal device 400 to complete the relevant data calculation of the virtual scene 100, such as stand-alone / offline mode games, and complete the output of the virtual scene through various types of terminal devices 400 such as smart phones, tablet computers, and virtual reality / augmented reality devices.
[0065] When forming the visual perception of the virtual scene 100, the terminal device 400 calculates the data required for display through the graphics computing hardware, and completes the loading, parsing and rendering of the display data, and outputs the video frames that can form the visual perception of the virtual scene on the graphics output hardware, for example, presenting two-dimensional video frames on the display screen of a smartphone, or projecting video frames on the lenses of augmented reality / virtual reality glasses to achieve a three-dimensional display effect; in addition, in order to enrich the perception effect, the terminal device 400 can also use different hardware to form one or more of auditory perception, tactile perception, motion perception and taste perception.
[0066] As an example, a client 410 (e.g., a stand-alone game application) is running on the terminal device 400. During the operation of the client 410, a virtual scene including role-playing is output. The virtual scene can be an environment for game characters to interact, such as a plain, street, valley, etc. for game characters to fight. Taking the first-person perspective display of the virtual scene 100 as an example, virtual objects 110 and interactive objects 120 are displayed in the virtual scene 100. The virtual object 110 can be a game character controlled by a user (or player), that is, the virtual object 110 is controlled by the real user and will move in the virtual scene 100 in response to the real user's operation on the controller (e.g., a touch screen, voice-controlled switch, keyboard, mouse, joystick, etc.). For example, when the real user moves the joystick to the right, the virtual object 110 will move to the right in the virtual scene 100. The virtual object 110 can also remain stationary, jump, and control the virtual object 110 to perform shooting operations. The interactive objects 120 are non-player characters in the virtual scene 100 (e.g., virtual props such as boxes, stones, and cars).
[0067] For example, a virtual object 110 and an interactive object 120 are displayed in a virtual scene 100. The client 410 responds to the movement operation of the virtual object 110 toward the interactive object 120 (for example, receiving a click operation of the player controlling the virtual object 110 to run toward the interactive object 120 in the virtual scene 100) and displays an animation of the virtual object 110 moving toward the interactive object 120 in the virtual scene 100. Subsequently, when the interaction conditions between the virtual object 110 and the interactive object 120 are met, the client 410 responds to the triggering operation of the interactive control 130 displayed on the interactive object 120 through the virtual object 110 (for example, receiving a click operation of the player on the icon 130 of the interactive control displayed in the virtual scene 100) and displays the interaction animation of the virtual object 110 and the interactive object 120 in the virtual scene 100. In this way, the interaction mode of the virtual scene is enriched and the player's gaming experience is improved.
[0068] In another implementation scenario, refer to Figure 1B, which is a schematic diagram of the second application mode of the virtual scene interactive data processing method provided in an embodiment of the present application, which is applied to the terminal device 400 and the server 200, and is suitable for relying on the computing power of the server 200 to complete the virtual scene calculation and output the application mode of the virtual scene on the terminal device 400.
[0069] Taking the visual perception of the virtual scene 100 as an example, the server 200 calculates the virtual scene-related display data (such as scene data) and sends it to the terminal device 400 through the network 300. The terminal device 400 relies on the graphics computing hardware to complete the loading, parsing and rendering of the display data, and relies on the graphics output hardware to output the virtual scene to form visual perception. For example, a two-dimensional video frame can be presented on the display screen of a smartphone, or a video frame with a three-dimensional display effect can be projected on the lenses of augmented reality / virtual reality glasses; for the perception of the form of the virtual scene, it can be understood that the corresponding hardware output of the terminal device 400 can be used, such as using a microphone to form auditory perception, using a vibrator to form tactile perception, and so on.
[0070] As an example, a client 410 (such as an online version of a game application) is running on the terminal device 400, which interacts with other users in a game by connecting to a server 200 (such as a game server). The terminal device 400 outputs the virtual scene 100 of the client 410. Taking the first-person perspective display of the virtual scene 100 as an example, virtual objects 110 and interactive objects 120 are displayed in the virtual scene 100, wherein the virtual object 110 can be a game character controlled by the user, that is, the virtual object 110 is controlled by the real user and will move in the virtual scene 100 in response to the real user's operation on the controller (such as a touch screen, voice-controlled switch, keyboard, mouse and joystick, etc.). For example, when the real user moves the joystick to the right, the virtual object 110 will move to the right in the virtual scene 100, and can also remain still, jump, and control the virtual object 110 to perform shooting operations, etc.; the interactive object 120 is a non-player character in the virtual scene 100 (such as virtual props such as boxes, stones, cars, etc.).
[0071] For example, a virtual object 110 and an interactive object 120 are displayed in a virtual scene 100. The client 410 responds to the movement operation of the virtual object 110 toward the interactive object 120 (for example, receiving a click operation of the player controlling the virtual object 110 to run toward the interactive object 120 in the virtual scene 100) and displays an animation of the virtual object 110 moving toward the interactive object 120 in the virtual scene 100. Subsequently, when the interaction conditions between the virtual object 110 and the interactive object 120 are met, the client 410 responds to the triggering operation of the interactive control 130 displayed on the interactive object 120 through the virtual object 110 (for example, receiving a click operation of the player on the icon 130 of the interactive control displayed in the virtual scene 100) and displays the interaction animation of the virtual object 110 and the interactive object 120 in the virtual scene 100. In this way, the interaction mode of the virtual scene is enriched and the player's gaming experience is improved.
[0072] In some embodiments, the terminal device or server can implement the virtual scene interactive data processing method provided by the embodiment of the present application by running various computer executable instructions or computer programs. For example, computer executable instructions can be commands, machine instructions or software instructions at the microprogram level. The computer program can be a native program or software module in the operating system; it can be a local (Native) application (APPlication, APP), that is, a program that needs to be installed in the operating system to run, such as a game APP; it can also be a small program that can be embedded in any APP, that is, a program that can be run only by downloading it to a browser environment. In short, the above-mentioned computer executable instructions can be instructions in any form, and the above-mentioned computer program can be an application, module or plug-in in any form.
[0073] Taking a computer program as an application, in actual implementation, the terminal device 400 installs and runs an application that supports a virtual scene. The application can be any of a first-person shooter (FPS), a third-person shooter, a virtual reality application, a three-dimensional map program, a card strategy game, a sports game, or a multiplayer shooter survival game. The user uses the terminal device 400 to manipulate virtual objects in the virtual scene to perform activities, including but not limited to: adjusting body posture, crawling, walking, running, riding, jumping, driving, picking up, shooting, attacking, throwing, and constructing virtual buildings. Illustratively, the virtual character can be a virtual person, such as a simulated human character or an anime character.
[0074] It should be noted that the solution for the collaborative implementation of terminal devices and servers mainly involves two game modes, namely local game mode and cloud game mode. Among them, the local game mode refers to the terminal device and the server jointly running the game processing logic. The operation instructions entered by the player in the terminal device are partially processed by the terminal device running the game logic, and the other part is processed by the server running the game logic. In addition, the game logic processing run by the server is often more complex and requires more computing power. The cloud game mode refers to the game logic processing being completely run by the server (such as a cloud server), and the cloud server renders the game scene data into an audio and video stream, which is then transmitted to the terminal device through the network for display. In other words, the terminal device only needs to have basic streaming media playback capabilities and the ability to obtain the player's operation instructions and send them to the server.
[0075] In other embodiments, the embodiments of the present application may be implemented through artificial intelligence technology. Artificial Intelligence (AI) is the theory, method, technology, and application system that uses digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use knowledge to achieve optimal results. In other words, artificial intelligence is a comprehensive technology in computer science that attempts to understand the essence of intelligence and produce a new type of intelligent machine that can respond in a manner similar to human intelligence. Artificial intelligence is the study of the design principles and implementation methods of various intelligent machines, so that machines have the functions of perception, reasoning, and decision-making.
[0076] Artificial intelligence (AI) technology is a comprehensive discipline encompassing a wide range of fields, encompassing both hardware and software technologies. Foundational AI technologies generally include sensors, specialized AI chips, cloud computing, distributed storage, big data processing, pre-trained models, operating / interaction systems, and mechatronics. Pre-trained models, also known as large models or basic models, can be fine-tuned and widely applied to downstream tasks across various AI disciplines. AI software technologies primarily encompass computer vision, speech processing, natural language processing, and machine learning / deep learning.
[0077] In some embodiments, the server 200 can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence platforms. The terminal device 400 can be a smart phone, a tablet computer, a laptop computer, a desktop computer, a smart speaker, a smart watch, a car terminal, etc., but is not limited to this. The terminal and the server can be directly or indirectly connected via wired or wireless communication, which is not limited in the embodiments of the present application.
[0078] Referring to FIG. 2 , FIG. 2 is a schematic diagram of the structure of a terminal device 400 provided in an embodiment of the present application. The terminal device 400 shown in FIG. 2 includes: at least one processor 460, a memory 450, at least one network interface 420, and a user interface 430. The various components in the terminal device 400 are coupled together via a bus system 440. It will be understood that the bus system 440 is used to implement connection and communication between these components. In addition to including a data bus, the bus system 440 also includes a power bus, a control bus, and a status signal bus. However, for the sake of clarity, in FIG. 2 , all of the various buses are labeled as the bus system 440.
[0079] The processor 460 can be an integrated circuit chip with signal processing capabilities, such as a general-purpose processor, a digital signal processor (DSP), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc., where the general-purpose processor can be a microprocessor or any conventional processor, etc.
[0080] The user interface 430 includes one or more output devices 431 that enable presentation of media content, including at least one of the following: one or more speakers, one or more visual display screens. The user interface 430 also includes one or more input devices 432, including user interface components that facilitate user input, such as a keyboard, mouse, microphone, touch screen display, camera, other input buttons and controls.
[0081] The memory 450 may be removable, non-removable, or a combination thereof. Exemplary hardware devices include solid-state memory, hard drives, optical drives, etc. The memory 450 may optionally include one or more storage devices that are physically remote from the processor 460.
[0082] The memory 450 includes volatile memory or non-volatile memory, or may include both volatile and non-volatile memory. The non-volatile memory may be a read-only memory (ROM), and the volatile memory may be a random access memory (RAM). The memory 450 described in the embodiments of the present application is intended to include any suitable type of memory.
[0083] In some embodiments, the memory 450 can store data to support various operations, examples of which include programs, modules, and data structures, or a subset or superset thereof, as exemplified below.
[0084] Operating system 451, including system programs for processing various basic system services and performing hardware-related tasks, such as the framework layer, core library layer, and driver layer, which are used to implement various basic services and process hardware-based tasks;
[0085] A network communication module 452 is used to reach other electronic devices via one or more (wired or wireless) network interfaces 420. Exemplary network interfaces 420 include Bluetooth, Wi-Fi, and Universal Serial Bus (USB);
[0086] a presentation module 453 for enabling presentation of information via one or more output devices 431 (e.g., a display screen, a speaker, etc.) associated with the user interface 430 (e.g., a user interface for operating peripheral devices and displaying content and information);
[0087] The input processing module 454 is configured to detect one or more user inputs or interactions from one of the one or more input devices 432 and to translate the detected inputs or interactions.
[0088] In some embodiments, the apparatus provided in the embodiments of the present application can be implemented in software. FIG2 shows a virtual scene interactive data processing apparatus 455 stored in a memory 450. The apparatus 455 can be software in the form of a program or plug-in, and includes the following software modules: a display module 4551, an acquisition module 4552, a first determination module 4553, a second determination module 4554, and a data adjustment module 4555. These modules are logical and can be arbitrarily combined or further separated according to the functions implemented. The functions of each module will be described below.
[0089] The virtual scene interactive data processing method provided in the embodiment of the present application will be explained in combination with the exemplary application and implementation of the terminal device provided in the embodiment of the present application.
[0090] Refer to Figure 3A, which is a first flow chart of the virtual scene interactive data processing method provided in an embodiment of the present application. The terminal device is used as the execution body and the steps shown in Figure 3A will be explained.
[0091] In step 101 , virtual objects and interactive objects are displayed in a virtual scene.
[0092] In some embodiments, the virtual scene may be an online game scene, the virtual object may be a player character corresponding to the user in the online game, and the interactive object may be a non-player character that interacts with the player character.
[0093] In step 102 , in response to the virtual object satisfying an interaction condition between the virtual object and the interactable object at a first moment, a current posture of the virtual object at the first moment is obtained.
[0094] In some embodiments, the interaction condition includes: the distance between the virtual object and the interactive object at a first moment is less than or equal to a distance threshold. The distance threshold can be determined by: the distance threshold can be pre-set, or the speed of the virtual object can be obtained; the speed can be multiplied by a preset duration, and the product can be used as the distance threshold.
[0095] For example, a may be preset as a distance threshold, or if the speed of the virtual scene is v1 and the preset time duration is t1, the distance threshold is v1*t1.
[0096] For example, the speed of the virtual object may be various types of speeds, such as maximum speed, minimum speed, average speed, etc.
[0097] For example, different moments can be set according to fixed time lengths, such as one minute, a quarter of an hour, one hour, etc. The first moment is the moment when the interaction condition is met, and the second moment is the moment after the preset time length is counted from the first moment.
[0098] In some embodiments, the preset duration may be fixed, and may be set by the player according to his or her own usage habits, for example, by providing the player with a duration selection range and allowing the player to select a duration as the preset duration.
[0099] In other embodiments, the preset duration may be dynamic, and the preset duration may be positively correlated with the speed at which the player manipulates the virtual object (e.g., average speed), that is, the faster the speed, the shorter the preset duration, thereby achieving player manipulation and automatic interaction in terms of visual effects.
[0100] For example, the relationship between the preset duration and the speed at which the player manipulates the virtual object can be expressed as: y=ax+b, where x is the speed at which the player manipulates the virtual object, y is the preset duration, a is a positive number, and b is an arbitrary real number.
[0101] In other embodiments, the preset duration can be predicted by a machine learning model. The training sample can be a video clip of a virtual scene, including the process of a virtual object switching from not interacting with an interactive object to interacting with an interactive object. The label data can be the appropriate switching duration calibrated by the player based on their habits. The machine learning model can then learn the player's needs for the appropriate duration.
[0102] In some embodiments, before calling the machine learning model for prediction processing, the following processing can also be performed: obtaining training samples; calling the initialized machine learning model for prediction processing based on the training samples to obtain prediction results; determining the loss value between the prediction results and the label data, and performing backpropagation based on the loss value, and updating the parameters of the machine learning model layer by layer during the backpropagation process.
[0103] For example, the exemplary structure of the machine learning model provided in the embodiment of the present application may include: an input layer (i.e., an embedding layer), an encoding layer (for example, it may be composed of multiple cascaded convolutional layers), a fully connected layer, and an output layer (including an activation function, such as a Softmax function). After obtaining the training sample, the feature information of the training sample can first be input into the input layer for embedding processing, and then the embedded feature vector output by the input layer can be encoded through the encoding layer to obtain a hidden layer feature vector, and then the hidden layer feature vector can be fully connected through the fully connected layer. Finally, the fully connected result output by the fully connected layer can be input into the output layer so that the output layer is activated to obtain a prediction result. After obtaining the prediction result, the prediction result and the label data pre-labeled for the training sample can be substituted into the loss function to obtain a loss value in a specific form between the prediction result and the label data, wherein the specific form includes at least one of the following: logarithmic form, exponential form, square form, cross entropy form and absolute value form, and the gradient of the loss function with respect to the model parameters is calculated through the back propagation algorithm, and the model parameters are adjusted based on the gradient and learning rate using gradient descent or other optimization algorithms. The process of forward propagation, loss calculation, back propagation and parameter update is repeated until the model converges or reaches the predetermined number of training rounds to obtain a trained machine learning model.
[0104] It should be noted that the machine learning model in the embodiments of the present application can be a neural network model (such as a convolutional neural network, a deep convolutional neural network, or a fully connected neural network), a decision tree model, a gradient boosting tree, a multi-layer perceptron, and a support vector machine, etc. The embodiments of the present application do not specifically limit the type of machine learning model.
[0105] The embodiment of the present application predicts the preset duration by training a machine learning model, so that the predicted duration is more in line with the player's usage habits and a reasonable preset duration can be quickly obtained.
[0106] In some embodiments, the interaction condition includes: receiving an operation instruction to trigger a control prop at a first moment, wherein the control prop is used to control the interactive object to interact with the virtual object.
[0107] In some embodiments, the second moment can be the moment when the virtual object begins to interact with the interactive object. Specifically, there are two situations: 1. The second moment can be a moment at least a preset time after the first moment, wherein the preset time is fixed. When the virtual object reaches the preset time after the first moment, it just completes the posture conversion and adjusts to the reference posture. The preset time can be set by the game developer or by the user. The second moment can be the moment when the preset time ends, that is, the virtual object directly starts to interact with the interactive object after converting to the reference posture at the second moment; the second moment can also be any moment after the preset time, that is, when the virtual object converts to the reference posture at the last moment of the preset time, it does not directly interact, but does not interact until the second moment. In this case, the second moment is determined by the user. 2. The second moment may also be the moment when the virtual object enters the interaction range of the interactive object (an area centered on the interactive object, such as a circle, the size of which depends on the influence radius of the function of the interactive object). The second moment may be the moment when the virtual object just enters the interaction range of the interactive object. At this time, it is just converted to the reference posture and starts to interact with the interactive object at the same time. The second moment may also be any moment after entering the interaction range of the interactive object. The virtual object has already converted to the reference posture before the second moment, but has not interacted with the interactive object until the second moment. At this time, the second moment is controlled by the user.
[0108] For example, the first time is 1:30. For the first case above, if the preset duration is 30 minutes, then the virtual object is completely converted to the reference pose at 2:00. If the virtual object can directly start interacting with the interactive object after converting to the reference pose at 2:00, the second time is 2:00. If the virtual object does not start interacting with the interactive object at 2:00, the second time can be any time after 2:00. In this case, the second time is determined by the user.
[0109] For the second case mentioned above, if the virtual object reaches the interaction range of the interactive object at 2:00 and starts to interact with the interactive object at 2:00, then the second moment is 2:00; if the virtual object completes the posture transformation at 1:40 and has reached the interaction range of the interactive object, but does not start to interact with the interactive object until 2:00, then 2:00 is the second moment. At this time, the second moment is determined by the user.
[0110] For example, the control prop may be a remote controller, and the interactive object may be an aircraft or vehicle (aeroplane, car) that can be remotely controlled by the remote controller.
[0111] In some embodiments, before step 102, it can be determined whether the virtual object meets the interaction conditions at the first moment: in response to not meeting the interaction conditions, the interactive controls of the interactive object are shielded; in response to meeting the interaction conditions, the interactive controls of the interactive object are displayed from the first moment.
[0112] For example, when the interaction condition is not met, the interaction control may not be displayed on the interactable object, and the interaction control may not be displayed on the interactable object until the virtual object meets the interaction condition.
[0113] The embodiment of the present application sets interaction conditions to avoid the virtual object accidentally touching the interactive control before interacting with the interactive object, thereby preventing the player's gaming experience from being affected. It can also avoid triggering the interactive control multiple times and reduce resource waste.
[0114] In some embodiments, the interactive control may be displayed throughout the interaction process with the interactive object, and placed in an untriggerable state when the interaction condition is not met, and placed in a triggerable state when the interaction condition is met.
[0115] For example, the untriggerable state can be graying out interactive controls, meaning they cannot be triggered. Players can see interactive controls on interactable objects at any time, but they can only be triggered when the interaction conditions are met. If the interaction conditions are not met, the interactive control cannot be triggered even if it is clicked.
[0116] In some embodiments, after the interaction conditions are met and the interactive control is in a triggerable state, referring to FIG3H , which is a schematic diagram of the eighth flow chart of the virtual scene interaction data processing method provided in an embodiment of the present application, the interaction operation between the virtual object and the interactive object can be implemented through step 106 of FIG3H , which is described in detail below.
[0117] In step 106 , in response to a triggering operation on the interactive control, the interactive object is controlled to interact with the virtual object.
[0118] The embodiments of the present application set different states for interactive controls in different situations to avoid accidental touching of interactive controls by virtual objects before interacting with interactive objects, thereby preventing the player's gaming experience from being affected. At the same time, it can also avoid triggering interactive controls multiple times and reduce resource waste.
[0119] In step 103 , a pose difference between the current pose and a reference pose is determined, wherein the reference pose is an initial pose of the virtual object in the interaction with the interactive object.
[0120] In some embodiments, the current pose includes the following components: a first position, a first posture, and a first orientation of the virtual object at a first moment, and the reference pose includes the following components: a second position, a second posture, and a second orientation of the virtual object in interaction with an interactive object (e.g., a pre-made animation representing the interaction).
[0121] As an example, the reference pose may be the initial pose in the interaction between the virtual object and the interactive object (e.g., a pre-made animation representing the interaction), that is, if the virtual object starts interacting with the interactive object from a second moment, the second moment is the initial moment of the interaction, and the pose of the virtual object at the second moment includes a second position, a second posture, and a second orientation.
[0122] The reference pose can be pre-set based on the position, orientation, and interaction method of the interactive object. For example, if the interactive object is a safe, then to open the safe, you need to stand in front of the safe, facing the safe, and put away the gun. Accordingly, the virtual object's position in front of the safe, facing the safe, and the posture of putting away the gun constitutes the reference pose.
[0123] For example, position, posture, and orientation can all be represented in the world coordinate system. As shown in Figure 6, Figure 6 is a schematic diagram of the position and orientation of the virtual object in the world coordinate system provided by this embodiment. The first position of the virtual object at the first moment is (x1, y1, 0), where x1 is the first horizontal coordinate, y1 is the first vertical coordinate, 0 indicates that the virtual object is active on the surface of the virtual scene (such as the ground or the water surface), so the vertical coordinate (coordinate on the z-axis) is 0, the first orientation is ∠1 degrees, and the first posture is holding the props. The second position of the virtual object at the second moment is (x2, y2, 0), where x2 is the second horizontal coordinate, y2 is the second vertical coordinate, 0 indicates that the virtual object is active on the surface of the virtual scene (such as the ground or the water surface), so the vertical coordinate (coordinate on the z-axis) is 0, the second orientation is ∠2 degrees, and the second posture is empty-handed. The ground plane of the virtual scene is the xoy plane, the origin is the center point of the virtual scene, the x-axis is a straight line passing through the origin and parallel to the horizontal boundary line of the virtual scene, and the y-axis is a longitudinal straight line perpendicular to the x-axis.
[0124] In some embodiments, the interaction between the virtual object and the interactable object (eg, including an animation of the interaction process) may be executed starting at the second moment.
[0125] In other embodiments, the interaction between the virtual object and the interactive object may also be started at a time after the second time, that is, the interaction is not limited to starting at the second time. For example, if the second time is time t (in seconds), the third time may be t+1, t+2, t+3, etc. The specific delay can be set according to the actual delay requirements of the virtual scene.
[0126] For example, the virtual object has switched from the current posture at the first moment to the reference posture at the second moment. At this time, the player can directly click the interaction control to directly start the interaction between the virtual object and the interactive object, or start the interaction between the virtual object and the interactive object 5 seconds after the second moment.
[0127] The embodiment of the present application freely controls the start time of the interaction, so that the interaction process is more in line with the player's usage habits, thereby improving the player's usage experience.
[0128] In some embodiments, taking the interaction between a virtual object and an interactive object (e.g., including animation of the interaction process) as an example, see FIG3B , which is a second flow diagram of the virtual scene interaction data processing method provided by an embodiment of the present application. Step 103 of FIG3A , "Determining the posture difference between the current posture and the reference posture," can be implemented through steps 1031 to 1034 of FIG3B , as described in detail below.
[0129] In step 1031 , a position difference between the first position and the second position is determined as the position difference.
[0130] In some embodiments, the first position and the second position are both three-dimensional coordinate data in the world coordinate system. Since virtual objects in the virtual environment move on the surface of the virtual scene (such as the ground or water surface), the position difference only calculates the position difference of the virtual object on the x-axis and y-axis during the calculation process.
[0131] For example, if the first position is (x1, y1) and the second position is (x2, y2), the position difference of the virtual object on the x-axis is x2-x1, and the position difference of the virtual object on the y-axis is y2-y1.
[0132] In step 1032 , a posture difference between the first posture and the second posture is determined as a posture difference.
[0133] In some embodiments, the first posture may be holding a prop, and the second posture may be empty-handed, so the posture difference represents the movement change process from holding a prop to empty-handed.
[0134] For example, since the virtual object needs to interact with the interactive object at the second moment, the second posture needs to be in an empty-handed state to trigger the interactive control to complete the interaction. Switching the posture to an empty-handed state is a preparatory action before the interaction.
[0135] In step 1033 , an orientation difference between the first orientation and the second orientation is determined as the orientation difference.
[0136] In some embodiments, the first orientation and the second orientation are both three-dimensional coordinate data in the world coordinate system. The virtual object moves on the surface of the virtual scene in the virtual environment. Therefore, the orientation difference only calculates the difference in the rotation angle of the virtual object around the z-axis during the calculation process.
[0137] For example, the rotation angle of the virtual object around the z-axis at the first moment is ∠1, and the rotation angle of the virtual object around the z-axis at the second moment is ∠2, then the orientation difference is ∠2-∠1.
[0138] In step 1034 , the position difference, posture difference, and orientation difference are combined into a pose difference.
[0139] For example, referring to Figure 6, the posture difference can be divided into lateral position difference and longitudinal position difference. The lateral position difference is x1-x2, the longitudinal position difference is y1-y2, the posture difference is from holding the prop to empty hands, and the orientation difference is ∠1-∠2.
[0140] Continuing to refer to FIG. 3A , in step 104 , a ratio of the posture difference to the transition frame number is determined as a posture adjustment value, wherein the transition frame number is the number of image frames between the first moment and the second moment.
[0141] In some embodiments, the ratio of the posture difference to the transition frame number can reflect the posture change of the virtual object in each frame from the first moment to the second moment, that is, the posture adjustment value.
[0142] For example, taking the position difference as an example, if the position of the virtual object at the first moment is (x1, y1), and the position at the second moment is (x2, y2), and the number of transition frames from the first moment to the second moment is 60, then the position difference of the horizontal coordinate is x1-x2, then the horizontal position adjustment value is (x1-x2) / 60, and the position difference of the vertical coordinate is y1-y2, then the vertical position adjustment value is (y1-y2) / 60.
[0143] For example, there are many ways to obtain the transition frame number, for example, it can be determined by setting a preset value of the transition frame number; for another example, it can be adapted to the frame rate of the virtual scene, that is, the product of the preset duration and the frame rate is used as the transition frame number.
[0144] For example, the preset value may be set to 5 as the number of transition frames; the preset duration may also be set to a and the frame rate to b, and the number of transition frames is a*b.
[0145] In step 105 , the virtual object is controlled to implement the posture adjustment value in each image frame from the first moment to the second moment.
[0146] In some embodiments, when the current pose component includes the first position, refer to FIG3C , which is a third flow chart of the virtual scene interaction data processing method provided by an embodiment of the present application. Step 105 of FIG3A can be implemented through steps 1051A to 1052A of FIG3C , as described in detail below.
[0147] In step 1051A, a ratio of the position difference to the number of transition frames is determined as a position adjustment value.
[0148] For example, if the total time from the first moment to the second moment is 1 second, that is, the number of transition frames is 60 frames, and referring to Figure 6, the position difference at this time is x1-x2 in the horizontal coordinate, then the horizontal position adjustment value is (x1-x2) / 60, and the vertical coordinate is y1-y2, then the vertical position adjustment value is (y1-y2) / 60.
[0149] In step 1052A, in response to the position adjustment value being a non-zero value, in each image frame between the first moment and the second moment, the virtual object is controlled to implement the position adjustment value based on the position of the root bone point of the virtual object in the previous frame to form the position in the current frame.
[0150] In some embodiments, a skeletal structure is a hierarchy of bones connected in series. The first bone, called the root bone, is the key point in the skeletal structure. All other bones, acting as child bones or sibling bones, are attached to the root bone. The root bone point refers to the coordinate point corresponding to the root bone in the world coordinate system.
[0151] In some embodiments, the first position includes the first plane coordinates of the virtual object corresponding to the world coordinate system at the first moment, the first plane coordinates include a first horizontal coordinate and a first vertical coordinate, and the second position includes the second plane coordinates of the virtual object corresponding to the world coordinate system at the second moment, the second plane coordinates include a second horizontal coordinate and a second vertical coordinate.
[0152] In some embodiments, referring to FIG3D , FIG3D is a fourth flow diagram of the virtual scene interaction data processing method provided by an embodiment of the present application. Step 1052A of FIG3C , "Controlling the Virtual Object to Implement Position Adjustment Values," can be implemented via steps 10521A to 10525A of FIG3D , as described in detail below.
[0153] In step 10521A, a transverse coordinate difference between the first transverse coordinate and the second transverse coordinate is determined.
[0154] In some embodiments, the lateral coordinate difference is a difference between a position coordinate of the virtual object on the x-axis at a first moment and a position coordinate of the virtual object on the x-axis at a second moment.
[0155] For example, referring to FIG6 , the first horizontal coordinate of the virtual object on the x-axis at the first moment is x1, and the second horizontal coordinate on the x-axis at the second moment is x2. The horizontal coordinate difference at this time is x1-x2.
[0156] In step 10522A, the ratio of the horizontal coordinate difference to the transition frame number is determined as the horizontal position adjustment value.
[0157] In some embodiments, the ratio of the horizontal coordinate difference to the transition frame number represents the position change of the virtual object on the x-axis from the first moment to the second moment in each frame, that is, the horizontal position adjustment value.
[0158] For example, if the total duration from the first moment to the second moment is 1 second, that is, the number of transition frames is 60 frames, and referring to FIG6 , the horizontal coordinate difference at this time is x1-x2, and the horizontal position adjustment value is (x1-x2) / 60.
[0159] In step 10523A, the longitudinal coordinate difference between the first longitudinal coordinate and the second longitudinal coordinate is determined.
[0160] In some embodiments, the longitudinal coordinate difference is the difference between the position coordinate of the virtual object on the y-axis at a first moment and the position coordinate of the virtual object on the y-axis at a second moment.
[0161] For example, referring to FIG6 , the first longitudinal coordinate of the virtual object on the y-axis at the first moment is y1 , and the second longitudinal coordinate on the y-axis at the second moment is y2 , and the longitudinal coordinate difference at this time is y1 −y2 .
[0162] In step 10524A, the ratio of the longitudinal coordinate difference to the transition frame number is determined as the longitudinal position adjustment value.
[0163] For example, if the total duration from the first moment to the second moment is 1 second, that is, the number of transition frames is 60 frames, and referring to FIG6 , the longitudinal coordinate difference at this time is y1-y2, and the longitudinal position adjustment value is (y1-y2) / 60.
[0164] In some embodiments, the ratio of the longitudinal coordinate difference to the transition frame number represents the position change of the virtual object on the y-axis from the first moment to the second moment in each frame, that is, the longitudinal position adjustment value.
[0165] In step 10525A, the virtual object is controlled to adjust its lateral position according to the lateral position adjustment value, and to adjust its longitudinal position according to the longitudinal position adjustment value.
[0166] In some embodiments, when the current pose component includes the first posture, refer to FIG3E , which is a fifth flow chart of the virtual scene interaction data processing method provided by an embodiment of the present application. Step 105 of FIG3A can be implemented through steps 1051B to 1052B of FIG3E , as described in detail below.
[0167] In step 1051B, the ratio of the posture difference value to the transition frame number is determined as the posture adjustment value.
[0168] In step 1052B, in response to the posture adjustment value being a non-zero value, in each image frame between the first moment and the second moment, the virtual object is controlled to implement the posture adjustment value based on the posture of the virtual object in the previous frame to form the posture in the current frame.
[0169] In some embodiments, the virtual object is in a posture of holding a prop in the image frame at the first moment, and the virtual object is in a posture of being empty-handed in the image frame at the second moment.
[0170] For example, the virtual object may be in a state of holding a prop at the first moment. When the interaction conditions are met, since the virtual object needs to interact with the interactive object from the second moment on, it is necessary to put away the prop and click the interactive control with empty hands to complete the interaction.
[0171] The embodiment of the present application switches postures to make the virtual object move from an interactive object to an interactive object, and in the process of interaction after conversion to a reference posture, the movements are smoother, and the interactive operations are completed in a bare-handed state, making the interaction process more in line with reality and enriching the user experience.
[0172] In some embodiments, when the current pose component includes a first orientation, refer to FIG3F , which is a sixth flow chart of the virtual scene interaction data processing method provided by an embodiment of the present application. Step 105 of FIG3A can be implemented through steps 1051C to 1052C of FIG3F , as described in detail below.
[0173] In step 1051C, a ratio of the orientation difference to the number of transition frames is determined as an orientation adjustment value.
[0174] In step 1052C, in response to the orientation adjustment value being a non-zero value, in each image frame between the first moment and the second moment, the virtual object is controlled to implement the orientation adjustment value based on the orientation of the root bone of the virtual object in the previous frame to form the orientation in the current frame.
[0175] In some embodiments, a skeletal structure is a hierarchy of bones connected in series. The first bone, called the root bone, is the key to the skeletal structure. All other bones, acting as child bones or sibling bones, are attached to the root bone.
[0176] In some embodiments, for skeletal animation, it is necessary to set the position and orientation of the model, which is actually to set the position and orientation of the root bone, and then calculate the position and orientation of each bone based on the transformation relationship between the parent and child bones in the bone hierarchy as the orientation of the virtual object.
[0177] In some embodiments, the first orientation includes a first rotated coordinate of the virtual object corresponding to the world coordinate system at a first moment, and the second orientation includes a second rotated coordinate of the virtual object corresponding to the world coordinate system at a second moment.
[0178] For example, the first rotation coordinate can be the angle of rotation of the virtual object around the z-axis starting from zero degrees at the first moment. The angle can be calculated by the rotation direction, for example, with clockwise rotation being positive. Continuing with FIG6 , the first orientation at this time is ∠1 degrees, and the second orientation is ∠2 degrees.
[0179] In some embodiments, referring to FIG3G , FIG3G is a seventh flow chart of the virtual scene interactive data processing method provided in an embodiment of the present application. Step 1052C of FIG3F can be implemented by steps 10521C to 10523C of FIG3G , as described in detail below.
[0180] In step 10521C, a rotation coordinate difference between the first rotation coordinate and the second rotation coordinate is determined.
[0181] In some embodiments, the rotation coordinate difference is a difference between an angle value of the virtual object rotated around the z-axis at a first moment and an angle value of the virtual object rotated around the z-axis at a second moment.
[0182] For example, if the angle value of the virtual object's rotation around the z-axis at the first moment is 30 degrees, and the angle value of the virtual object's rotation around the z-axis at the second moment is 90 degrees, the rotation coordinate difference is 60 degrees.
[0183] In step 10522C, the ratio of the rotation coordinate difference to the transition frame number is determined as the orientation adjustment value.
[0184] In some embodiments, the ratio of the rotation coordinate difference to the transition frame number represents the angle change formed by the virtual object rotating around the z-axis in each frame from the first moment to the second moment, that is, the orientation adjustment value.
[0185] Continuing with the example of step 10521 above, if the rotation coordinate difference is 60 degrees and the number of transition frames is 30 frames, the orientation adjustment value is 2.
[0186] In step 10523C, the virtual object is controlled to rotate around the vertical reference axis of the world coordinate system according to the orientation adjustment value, where the vertical reference axis is perpendicular to the plane of the world coordinate system.
[0187] In some embodiments, the rotation direction may be clockwise or counterclockwise, depending on whether the heading adjustment value is positive or negative.The plane of the world coordinate system includes a transverse reference axis and a longitudinal reference axis.
[0188] In some embodiments, the trigger threshold can be raised, that is, the interactive control is displayed and the trigger operation is allowed to be executed only when the current posture of the virtual object at the first moment is converted and completely consistent with the pre-set standard posture.
[0189] For example, when the virtual object completes the transformation to the standard posture, the interactive control is displayed on the interactive object, and the interaction between the virtual object and the interactive object is completed by triggering the interactive control; when the transformation is not completed, the interactive control is not displayed.
[0190] The embodiments of the present application set different states for interactive controls in different situations, or control the display nodes of interactive controls, to avoid accidental touching of interactive controls by virtual objects before interacting with interactive objects, thereby preventing the player's gaming experience from being affected. At the same time, it can also avoid triggering interactive controls multiple times and reduce resource waste.
[0191] The following describes an exemplary application of the embodiments of the present application in a practical application scenario.
[0192] In a virtual game scene involving teamwork, it is often necessary to interact with virtual objects and interactive objects to obtain the props needed during the game. The virtual scene interaction data processing method provided in the embodiments of the present application can obtain a posture adjustment value based on the posture difference between the virtual object at a first moment and a second moment, and adjust the current posture based on the posture adjustment value, so that the virtual object can interact naturally with the interactive object.
[0193] Refer to Figure 4A, which is a first schematic diagram of the application scenario of the virtual scene interaction data processing method provided in an embodiment of the present application. The application of the virtual scene interaction data processing method in an embodiment of the present application will be explained in conjunction with Figure 4A.
[0194] In FIG4A , it is first necessary to obtain the current posture of the virtual object at the first moment.
[0195] 4B, which is a second schematic diagram of an application scenario of the virtual scene interactive data processing method provided by an embodiment of the present application, shows the current position of the virtual object at the first moment.
[0196] In some embodiments, in the world coordinate system of the virtual object, the z-axis (i.e., the horizontal height of the character's position) is consistent with the reference posture and is both 0, because they are all standing on a normal horizontal ground, but the x-axis (lateral displacement of the horizontal plane) and the y-axis (longitudinal displacement of the horizontal plane) are different from the values of the reference posture.
[0197] At the same time, the x-axis and y-axis rotation values of the virtual object in the world coordinate system are consistent with the values of the reference pose. This is because the x-axis and y-axis control the horizontal and vertical rotation of the character. In normal gameplay, a standing virtual object does not rotate in these two positions, so their values are both 0 (degrees). The z-axis controls the virtual object's vertical rotation, which is reflected in the game as the rotation angle when the virtual object turns, so it will be different from the reference pose.
[0198] For example, the first position of the virtual object at the first moment is (2400, 300, 0), where 2400 is the first horizontal coordinate, 300 is the first vertical coordinate, the first posture at the first moment is holding the prop, and the first orientation at the first moment is (0, 0, 40), where 40 is the first rotation coordinate.
[0199] Continuing to refer to FIG. 4A , it is also necessary to obtain the reference pose of the virtual object at the second moment.
[0200] Referring to Figure 4C, which is a third schematic diagram of an application scenario of the virtual scene interactive data processing method provided by an embodiment of the present application, Figure 4C shows the reference position of the virtual object at the second moment.
[0201] For example, the second position of the virtual object at the second moment is (0, 0, 0), the second posture at the second moment is empty-handed, and the second orientation at the second moment is (0, 0, 0).
[0202] Continuing with FIG4A , the data difference between the current pose and the reference pose is recorded (equivalent to the pose difference value described above), and the relevant conversion operation is started. The conversion process is described in detail below:
[0203] First, as shown in image frame 401 of Figure 4A, if the first position of the virtual object is different from the second position of the standard interaction, the virtual object will start to move from the first position to the second position. At the same time, the entire conversion time is set to 1S, that is, 60 frames (the number of transition frames from the first moment to the second moment).
[0204] If the first orientation of the virtual object at this time (i.e., the world coordinate rotation value) is inconsistent with the second orientation at the standard interaction position, the character orientation will be adjusted during the 1 second process of moving to the second position mentioned above.
[0205] Next, as shown in image frame 402 of Figure 4A , the virtual object's first position in the world coordinate system, (2400, 300, 0), will experience a movement speed (i.e., position adjustment value) of 2400 / 60 = (40 / frame) on the X-axis, moving toward the second position. Similarly, a displacement of 300 / 60 = (5 / frame) will occur on the Y-axis. This one-second movement corrects the horizontal and vertical coordinates of the virtual object's skeleton.
[0206] As shown in the difference between the coordinate rotation values given above, the Z-axis rotation coordinate of the coordinate at the second moment is 0, and the rotation coordinate of the virtual object at the first moment is 40 (degrees). Then, during the displacement process, the Z-axis will produce a rotation displacement of 40 / 60 = (0.6666 (degrees) / per frame). Through one second of movement, the rotation coordinate of its skeleton is corrected (that is, the orientation is adjusted).
[0207] Then, as shown in image frame 403 of Figure 4A, if the virtual object is in a state of holding a prop at this time, and when the interaction is triggered, the virtual object needs to be empty-handed, the virtual object is controlled to switch from holding a prop to being empty-handed during the 1S process of moving to the second position. At this time, the virtual object has been converted from the current posture to the reference posture.
[0208] Finally, if the virtual object's skeletal parameters meet one or two of the three conditions above, the conversion operations associated with the conditions that meet them are not performed. For example, if the world displacement coordinates of the virtual object's root skeletal point are correct (i.e., the first condition, the virtual object's current position), no position conversion is performed; only the world rotation value (orientation) and posture conversion are performed. Once all three conversions are completed, as shown in image frame 404 of Figure 4A, the virtual object's skeletal parameters and posture are completely consistent with the first frame of the standard interactive action, causing the virtual object to trigger the interactive control and begin playing the interactive action.
[0209] Referring to Figure 4D , Figure 4D is a fourth schematic diagram illustrating an application scenario of the virtual scene interaction data processing method provided in an embodiment of the present application. Figure 4D illustrates a scenario in which a virtual object triggers an interactive control. In Figure 4D , virtual object 501 can interact with interactive object 502 by triggering interactive control 503.
[0210] In some embodiments, if a player triggers an interaction button and the three values fully meet the standard values, the interaction action will be played directly. The conversion process of these interaction actions together constitutes the transition animation seen by the virtual object after the interaction is triggered.
[0211] In some embodiments, in order to avoid the situation where "the virtual object is too far away from the standard interaction position, and when the coordinate conversion is completed within one second, the distance becomes longer, resulting in an average speed that is too fast when completing the coordinate conversion", the maximum distance at which the virtual object can trigger interaction can be set (that is, the length of the hypotenuse of the right triangle formed by the X and Y axes of the world displacement coordinates of the two).
[0212] Referring to Figure 4E , which is a fifth schematic diagram of an application scenario of the virtual scene interaction data processing method provided in an embodiment of the present application, A is the standard position for triggering interaction (second position), and C is the current position of the virtual object (first position). The length of AB is the difference between their Y-axis coordinates, and the length of BC is the difference between their X-axis coordinates. Their actual distance is the length of the hypotenuse AC of the triangle.
[0213] For example, by setting a threshold to prevent interactive controls from being displayed to virtual objects when the AC length exceeds a certain value, this can be effectively prevented. For example, if the maximum speed of a virtual object in the game is set to 1000, then the speed calculated by dividing the AC length by 1 second cannot exceed 1000, meaning the AC length cannot exceed 1000.
[0214] Refer to Figure 5, which is a flow chart of an application scenario of the virtual scene interactive data processing method provided in an embodiment of the present application.
[0215] First, the virtual object reaches the vicinity of the interactive object and determines whether the distance between the virtual object and the interactive object is within the distance threshold. If not, the interactive control will not be displayed. If within the range, the interactive control will be displayed.
[0216] Secondly, in response to the player's triggering operation on the interactive control, the current posture of the virtual object when clicking the interactive control is obtained, and it is determined whether the first position, first orientation and first posture of the virtual object are consistent with the reference posture. The inconsistent posture components are adjusted through the virtual scene interaction data processing method provided in the embodiment of the present application.
[0217] Finally, the adjusted data is re-judged. If there are still inconsistencies between the current pose components and the reference pose, the data is recorded and adjusted again until all current pose components are consistent with the reference pose. The interactive control is triggered and the corresponding interactive action is performed to achieve interaction between the virtual object and the interactive object.
[0218] The embodiment of the present application converts the current posture component of the virtual object at the first moment to the reference posture at the second moment frame by frame, so that the interaction process between the virtual object and the interactive object is more natural, and adjusts the virtual object to the reference posture, so that the triggering of the interactive control is easier, avoiding multiple triggering and reducing resource waste.
[0219] The following further describes an exemplary structure of the virtual scene interaction data processing device 455 provided in an embodiment of the present application implemented as a software module. In some embodiments, as shown in FIG2 , the software modules stored in the virtual scene interaction data processing device 455 in the memory 440 may include:
[0220] The display module 4551 is configured to display virtual objects and interactive objects in a virtual scene.
[0221] The acquisition module 4552 is configured to acquire a current posture of the virtual object at the first moment in response to the virtual object satisfying an interaction condition between the virtual object and the interactable object at the first moment.
[0222] The first determination module 4553 is configured to determine a posture difference between the current posture and a reference posture, wherein the reference posture is an initial posture of the virtual object in the interaction with the interactive object.
[0223] The second determination module 4554 is configured to determine a ratio of the posture difference to the transition frame number as a posture adjustment value, wherein the transition frame number is the number of image frames between the first moment and the second moment.
[0224] The data adjustment module 4555 is configured to control the virtual object to implement the posture adjustment value in each image frame from the first moment to the second moment.
[0225] In some embodiments, the interaction condition includes: the distance between the virtual object and the interactive object at a first moment is less than or equal to a distance threshold.
[0226] In some embodiments, the second moment is a moment after a preset time period is started from the first moment, and the distance threshold is determined by: obtaining the speed of the virtual object; determining the product of the speed and the preset time period, and using the product as the distance threshold.
[0227] In some embodiments, the preset duration is determined by any of the following methods: selecting any duration in a preset duration selection range as the preset duration; determining the preset duration based on the speed of the virtual object, wherein the preset duration is positively correlated with the speed of the virtual object; determining the preset duration based on a machine learning model, wherein the machine learning model is trained by performing the following processing: obtaining training samples and label data, wherein the training samples include video clips of multiple virtual scenes, and the video clip of each virtual scene includes the process of switching from the virtual object not interacting with the interactive object to the virtual object interacting with the interactive object, and the label data represents the real calibrated preset duration; calling the machine learning model based on the training sample to obtain a prediction result; determining a loss value based on the label data and the prediction result, and updating the parameters of the machine learning model based on the loss value to obtain a trained machine learning model.
[0228] In some embodiments, the interaction condition includes: receiving an operation instruction to trigger a control prop at a first moment, wherein the control prop is used to control the interactive object to interact with the virtual object.
[0229] In some embodiments, the current pose includes the following components: the first position, the first posture and the first orientation of the virtual object at the first moment, and the reference pose includes the following components: the second position, the second posture and the second orientation in the interaction between the virtual object and the interactive object; the first determination module 4553 is also configured to determine the position difference between the first position and the second position as a position difference; determine the posture difference between the first posture and the second posture as a posture difference; determine the orientation difference between the first orientation and the second orientation as an orientation difference; and combine the position difference, posture difference and orientation difference into a pose difference.
[0230] In some embodiments, the data adjustment module 4555 is further configured to determine the ratio of the position difference to the number of transition frames as a position adjustment value; in response to the position adjustment value being a non-zero value, in each image frame between the first moment and the second moment, based on the position of the root bone point of the virtual object in the previous frame, the virtual object is controlled to implement the position adjustment value to form the position in the current frame.
[0231] In some embodiments, the first position includes the first plane coordinate of the virtual object corresponding to the world coordinate system at the first moment, the first plane coordinate includes a first horizontal coordinate and a first vertical coordinate, and the second position includes the second plane coordinate of the virtual object corresponding to the world coordinate system at the second moment, the second plane coordinate includes a second horizontal coordinate and a second vertical coordinate; the data adjustment module 4555 is also configured to determine the horizontal coordinate difference between the first horizontal coordinate and the second horizontal coordinate; determine the ratio of the horizontal coordinate difference to the transition frame number as the horizontal position adjustment value; determine the vertical coordinate difference between the first vertical coordinate and the second vertical coordinate; determine the ratio of the vertical coordinate difference to the transition frame number as the vertical position adjustment value; control the virtual object to adjust the horizontal position according to the horizontal position adjustment value, and adjust the vertical position according to the vertical position adjustment value.
[0232] In some embodiments, the data adjustment module 4555 is further configured to determine the ratio of the posture difference to the number of transition frames as a posture adjustment value; in response to the posture adjustment value being a non-zero value, in each image frame between the first moment and the second moment, based on the posture of the virtual object in the previous frame, the virtual object is controlled to implement the posture adjustment value to form a posture in the current frame.
[0233] In some embodiments, the virtual object is in a posture of holding a prop in the image frame at the first moment, and the virtual object is in a posture of being empty-handed in the image frame at the second moment.
[0234] In some embodiments, the data adjustment module 4555 is further configured to determine the ratio of the orientation difference to the number of transition frames as an orientation adjustment value when the current posture component includes a first orientation; in response to the orientation adjustment value being a non-zero value, in each image frame between the first moment and the second moment, based on the orientation of the root bone of the virtual object in the previous frame, control the virtual object to implement the orientation adjustment value to form the orientation in the current frame.
[0235] In some embodiments, the first orientation includes the first rotation coordinate of the virtual object corresponding to the world coordinate system at the first moment, and the second orientation includes the second rotation coordinate of the virtual object corresponding to the world coordinate system at the second moment; the data adjustment module 4555 is also configured to determine the rotation coordinate difference between the first rotation coordinate and the second rotation coordinate; determine the ratio of the rotation coordinate difference to the transition frame number as the orientation adjustment value; control the virtual object to rotate around the vertical reference axis of the world coordinate system according to the orientation adjustment value, wherein the vertical reference axis is perpendicular to the plane of the world coordinate system.
[0236] In some embodiments, the data adjustment module 4555 is further configured to, in response to the interaction condition not being met, shield the interactive controls of the interactive object from being displayed; and in response to the interaction condition being met, display the interactive controls of the interactive object from the first moment onward.
[0237] In some embodiments, the data adjustment module 4555 is further configured to control the virtual object to implement the posture adjustment value in each image frame from the first moment until after the second moment, in response to a trigger operation on the interactive control, to control the interactive object to interact with the virtual object.
[0238] In some embodiments, the interactive object includes an interactive control. In response to the interaction condition not being met, the interactive control is in an untriggerable state; in response to the interaction condition being met, the interactive control is in a triggerable state.
[0239] In some embodiments, the data adjustment module 4555 is further configured to, in response to the virtual object's posture at the second moment being different from a pre-set standard posture, shield the interactive controls of the interactive object from display; and in response to the virtual object's posture at the second moment being the same as the pre-set standard posture, display the interactive controls of the interactive object at the second moment.
[0240] The present invention provides a computer program product comprising a computer program or computer-executable instructions stored in a computer-readable storage medium. A processor of an electronic device reads the computer-executable instructions from the computer-readable storage medium and executes the computer-executable instructions, causing the electronic device to perform the virtual scene interaction data processing method described in the present invention.
[0241] An embodiment of the present application provides a computer-readable storage medium storing computer-executable instructions, which stores computer-executable instructions or computer programs. When the computer-executable instructions or computer programs are executed by a processor, the processor will execute the virtual scene interaction data processing method provided by an embodiment of the present application, for example, the virtual scene interaction data processing method shown in Figure 3A.
[0242] In some embodiments, the computer-readable storage medium may be a memory such as RAM, ROM, flash memory, magnetic surface memory, optical disk, or CD-ROM; or may be various devices including one or any combination of the above memories.
[0243] In some embodiments, computer-executable instructions may be in the form of a program, software, software module, script, or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as a stand-alone program or as a module, component, subroutine, or other unit suitable for use in a computing environment.
[0244] As an example, computer-executable instructions may, but need not, correspond to a file in a file system, may be stored as part of a file that stores other programs or data, e.g., in one or more scripts in a HyperText Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple coordinating files (e.g., files storing one or more modules, subroutines, or code portions).
[0245] By way of example, computer-executable instructions may be deployed to be executed on one electronic device, or on multiple electronic devices located at one site, or on multiple electronic devices distributed across multiple sites and interconnected by a communication network.
[0246] To sum up, through the embodiments of the present application, the virtual object is converted frame by frame from the current posture at the first moment to the reference posture at the second moment, so that the interaction process between the virtual object and the interactive object is more natural, and the virtual object is adjusted to the reference posture, which makes it easier to trigger the interactive control, avoids multiple triggering, and reduces resource waste.
[0247] The above description is merely an embodiment of the present application and is not intended to limit the scope of protection of the present application. Any modifications, equivalent replacements, and improvements made within the spirit and scope of the present application are included in the scope of protection of the present application.
Claims
1. A method for processing virtual scene interaction data, the method being executed by an electronic device, the method comprising: Displaying virtual objects and interactive objects in a virtual scene; In response to the virtual object satisfying an interaction condition between the virtual object and the interactable object at a first moment, acquiring a current position and posture of the virtual object at the first moment; Determining a posture difference between the current posture and a reference posture, wherein the reference posture is an initial posture of the virtual object in the interaction with the interactive object; Determine a ratio of the posture difference value to the transition frame number as a posture adjustment value, wherein the transition frame number is the number of image frames between the first moment and the second moment; The virtual object is controlled to implement the posture adjustment value in each image frame from the first moment until the second moment.
2. The method according to claim 1, wherein: The interaction conditions include: At the first moment, the distance between the virtual object and the interactive object is less than or equal to a distance threshold.
3. The method according to claim 2, wherein: The second moment is a moment after a preset time period has elapsed since the first moment, and the method further includes: The distance threshold is determined by: Obtaining the speed of the virtual object; The product of the speed and the preset time length is determined, and the product is used as the distance threshold.
4. The method according to claim 3, wherein: The method further comprises: The preset duration is determined by any of the following methods: Select any duration in the preset duration selection range as the preset duration; Determining the preset duration based on the speed of the virtual object, wherein the preset duration is positively correlated with the speed of the virtual object; The preset duration is determined based on a machine learning model, wherein the machine learning model is trained by performing the following processing: obtaining training samples and label data, wherein the training samples include multiple video clips of the virtual scenes, each video clip of the virtual scene includes a process from the virtual object not interacting with the interactive object to the virtual object interacting with the interactive object, and the label data represents the preset duration of the real calibration; calling the machine learning model based on the training samples to obtain a prediction result; determining a loss value based on the label data and the prediction result, updating the parameters of the machine learning model based on the loss value, and obtaining the trained machine learning model.
5. The method according to any one of claims 1 to 4, wherein: The interaction conditions include: An operation instruction to trigger a control prop is received at the first moment, wherein the control prop is used to control the interactive object to interact with the virtual object.
6. The method according to any one of claims 1 to 6, wherein: The current pose includes the following components: a first position, a first posture, and a first orientation of the virtual object at the first moment, the reference pose comprising the following components: a second position, a second posture, and a second orientation of the virtual object in interaction with an interactable object; The determining of the posture difference between the current posture and the reference posture comprises: determining a position difference between the first position and the second position as a position difference; determining a posture difference between the first posture and the second posture as a posture difference; determining an orientation difference between the first orientation and the second orientation as an orientation difference; The position difference, the posture difference and the orientation difference are combined into the pose difference.
7. The method according to any one of claims 1 to 6, wherein: When the current posture component includes the first position, controlling the virtual object to implement the posture adjustment value in each image frame from the first moment until the second moment includes: Determine a ratio of the position difference to the transition frame number as a position adjustment value; In response to the position adjustment value being a non-zero value, in each image frame between the first moment and the second moment, the virtual object is controlled to implement the position adjustment value based on the position of the root bone point of the virtual object in the previous frame to form the position in the current frame.
8. The method according to claim 7, wherein: The first position includes a first plane coordinate of the virtual object corresponding to the world coordinate system at the first moment, the first plane coordinate includes a first horizontal coordinate and a first vertical coordinate, and the second position includes a second plane coordinate of the virtual object corresponding to the world coordinate system at the second moment, the second plane coordinate includes a second horizontal coordinate and a second vertical coordinate; The controlling the virtual object to implement the position adjustment value comprises: determining a transverse coordinate difference between the first transverse coordinate and the second transverse coordinate; Determine a ratio of the horizontal coordinate difference to the transition frame number as a horizontal position adjustment value; determining a longitudinal coordinate difference between the first longitudinal coordinate and the second longitudinal coordinate; Determine a ratio of the longitudinal coordinate difference to the transition frame number as a longitudinal position adjustment value; The virtual object is controlled to adjust its lateral position according to the lateral position adjustment value, and to adjust its longitudinal position according to the longitudinal position adjustment value.
9. The method according to any one of claims 1 to 6, wherein: When the current posture component includes the first posture, controlling the virtual object to implement the posture adjustment value in each image frame from the first moment until the second moment includes: Determine a ratio of the posture difference value to the transition frame number as a posture adjustment value; In response to the posture adjustment value being a non-zero value, in each image frame between the first moment and the second moment, based on the posture of the virtual object in the previous frame, the virtual object is controlled to implement the posture adjustment value to form a posture in the current frame.
10. The method according to claim 9, wherein: The virtual object is in a posture of holding a prop in the image frame at the first moment, and the virtual object is in a posture of being empty-handed in the image frame at the second moment.
11. The method according to any one of claims 1 to 6, wherein: When the current posture component includes the first orientation, controlling the virtual object to implement the posture adjustment value in each image frame starting from the first moment includes: Determine a ratio of the orientation difference to the number of transition frames as an orientation adjustment value; In response to the orientation adjustment value being a non-zero value, in each image frame between the first moment and the second moment, the virtual object is controlled to implement the orientation adjustment value based on the orientation of the root bone of the virtual object in the previous frame to form the orientation in the current frame.
12. The method according to claim 11, wherein: The first orientation includes a first rotation coordinate of the virtual object corresponding to the world coordinate system at the first moment, and the second orientation includes a second rotation coordinate of the virtual object corresponding to the world coordinate system at the second moment; The controlling the virtual object to implement the orientation adjustment value includes: Determining a rotation coordinate difference between the first rotation coordinate and the second rotation coordinate; Determine a ratio of the rotation coordinate difference to the transition frame number as the orientation adjustment value; The virtual object is controlled to rotate the orientation adjustment value around a vertical reference axis of the world coordinate system according to the orientation adjustment value, wherein the vertical reference axis is perpendicular to a plane of the world coordinate system.
13. The method according to any one of claims 1 to 12, wherein: The method further comprises: In response to not satisfying the interaction condition, shielding the interactive control of the interactive object from display; In response to satisfying the interaction condition, displaying an interaction control of the interactable object starting from the first moment.
14. The method according to claim 13, wherein: After controlling the virtual object to implement the posture adjustment value in each image frame from the first moment until the second moment, the method further includes: In response to a triggering operation on the interactive control, the interactive object is controlled to interact with the virtual object.
15. The method according to any one of claims 1 to 14, wherein: The interactive object includes an interactive control, and the method further includes: In response to not satisfying the interaction condition, setting the interaction control to a non-triggerable state; In response to satisfying the interaction condition, setting the interaction control to a triggerable state.
16. The method according to any one of claims 1 to 15, wherein: After controlling the virtual object to implement the posture adjustment value in each image frame from the first moment until the second moment, the method further includes: In response to the position and posture of the virtual object at the second moment being different from a preset standard position and posture, shielding and displaying an interactive control of the interactive object; In response to the posture of the virtual object at the second moment being the same as the preset standard posture, an interactive control of the interactive object is displayed at the second moment.
17. A virtual scene interactive data processing device, the device comprising: A display module configured to display virtual objects and interactive objects in a virtual scene; an acquisition module, configured to acquire a current position and posture of the virtual object at the first moment in response to the virtual object satisfying an interaction condition between the virtual object and the interactable object at the first moment; A first determination module is configured to determine a posture difference between the current posture and a reference posture, wherein the reference posture is an initial posture of the virtual object in the interaction with the interactive object; A second determination module is configured to determine a ratio of the posture difference value to a transition frame number as a posture adjustment value, wherein the transition frame number is the number of image frames between the first moment and the second moment; The data adjustment module is configured to control the virtual object to implement the posture adjustment value in each image frame from the first moment until the second moment.
18. An electronic device, comprising: A memory for storing computer executable instructions; The processor is used to implement the virtual scene interactive data processing method described in any one of claims 1 to 16 when executing the computer executable instructions stored in the memory.
19. A computer-readable storage medium storing computer-executable instructions or a computer program, wherein the computer-executable instructions or the computer program, when executed by a processor, implements the virtual scene interactive data processing method according to any one of claims 1 to 16.
20. A computer program product, comprising computer executable instructions or a computer program, wherein the computer executable instructions or the computer program, when executed by a processor, implements the virtual scene interactive data processing method according to any one of claims 1 to 16.
Citation Information
Patent Citations
Interaction method and device of virtual robot, electronic equipment and storage medium
CN110794964A
Virtual object pose control method and device and computer storage medium
CN112774203A
Animation generation method and device of virtual model, computer equipment and storage medium
CN115526967A
Virtual object control method and device, computer equipment and storage medium
CN115970287A
Intermediate frame generation method and device, equipment and storage medium
CN116030168A
Cited By
Method and device for generating character and dynamic scene interactive animation
CN120747317A