Three-dimensional model data processing method and apparatus, device, medium, and product
Patent Information
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2026-01-08
- Publication Date
- 2026-08-13
Smart Images

Figure CN2026071461_13082026_PF_FP_ABST
Abstract
Description
3D model data processing methods, devices, equipment, media and products
[0001] This application claims priority to Chinese Patent Application No. 202510130816.4, filed on February 5, 2025, entitled “Three-dimensional model data processing method, apparatus, device, medium and product”, the entire contents of which are incorporated herein by reference. Technical Field
[0002] This application relates to the field of image processing, and in particular to a method, apparatus, device, medium, and product for processing three-dimensional model data. Background Technology
[0003] In animation or game production, to ensure the realism of 3D models during animation, efforts are made to make their appearance as close to that of real people as possible. For example, when a virtual character is running, the shaking effect of the leg muscles during the lifting and lowering of the leg needs to be represented, and this shaking effect needs to match the softness of the skin.
[0004] In related technologies, modeling engineers typically draw skeletal chains for 3D models and design changes in the angles of these chains to represent the muscle trembling effect of the 3D model during movement.
[0005] However, the above solution involves high costs and a large workload in obtaining animation effects for the 3D model. Summary of the Invention
[0006] This application provides a method, apparatus, device, medium, and product for processing three-dimensional model data. The technical solution is as follows:
[0007] On the one hand, a method for processing three-dimensional model data is provided, the method being executed by a computer device, the method comprising:
[0008] A three-dimensional model of a first object is obtained, the three-dimensional model including at least one model part, the at least one model part including a first model part corresponding to the flexible body tissue of the first object;
[0009] The shape change trigger is invoked, and the shape change trigger is used to control the shape change of the first model part through deformation control parameters.
[0010] Acquire model motion data, which is used to control the movement of at least one model part so that the first object performs a first action;
[0011] Based on the model action data, the deformation control parameters are assigned values through the shape change trigger, and the shape change of the first model part is controlled accordingly to undergo the shape change during the execution of the first action, thereby obtaining shape change data.
[0012] On the other hand, a three-dimensional model data processing apparatus is provided, the apparatus comprising:
[0013] A first acquisition module is used to acquire a three-dimensional model of a first object, the three-dimensional model including at least one model part, the at least one model part including a first model part corresponding to the flexible body tissue of the first object;
[0014] The calling module is used to call the shape change trigger, which is used to control the shape change of the first model part through the deformation control parameters.
[0015] The second acquisition module is used to acquire model action data, which is used to control the movement of at least one model part so that the first object performs a first action.
[0016] The generation module is used to assign values to the deformation control parameters through the shape change trigger based on the model action data, and correspondingly control the first model part to undergo the shape change during the execution of the first action to obtain shape change data.
[0017] On the other hand, a computer device is provided, the computer device including a processor and a memory, the memory storing at least one instruction, at least one program, code set or instruction set, the at least one instruction, the at least one program, the code set or instruction set being loaded and executed by the processor to implement the three-dimensional model data processing method as described in any of the embodiments of this application above.
[0018] On the other hand, a computer-readable storage medium is provided, wherein at least one instruction, at least one program, code set, or instruction set is stored therein, wherein the at least one instruction, the at least one program, the code set, or the instruction set is loaded and executed by a processor to implement the three-dimensional model data processing method as described in any of the embodiments of this application above.
[0019] On the other hand, a computer program product or computer program is provided, which includes computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the computer device to perform any of the three-dimensional model data processing methods described in the above embodiments.
[0020] The technical solution provided in this application includes at least the following beneficial effects:
[0021] To depict the morphological changes of the flexible body tissue in the corresponding 3D model as the first object performs the first action, a morphological change trigger is used to represent these changes. This is achieved through model motion data corresponding to the first action and morphological change triggers bound to the first model portion. Specifically, a morphological change trigger is set for the first model portion corresponding to the flexible body tissue in at least one model portion participating in the execution of the first action. During the execution of the first action, the morphological change trigger deforms, causing the first model portion to jiggle. This results in a morphological change associated with the jiggle effect, realizing the dynamic jiggle effect of the flexible body tissue during the execution of the first action. This reduces the cost and workload of 3D model data processing while maintaining the realism of the 3D model's representation. For example, when the flexible body tissue is leg muscle, the morphological change trigger is invoked to control the leg muscle to produce realistic morphological changes when performing the first action (e.g., lifting the leg), thereby causing the model portion corresponding to the leg muscle to produce a corresponding motion effect, enhancing the realism of the 3D model's representation. Attached Figure Description
[0022] Figure 1 is a schematic diagram of an implementation environment provided by an exemplary embodiment of this application;
[0023] Figure 2 is a flowchart of a three-dimensional model data processing method provided in an exemplary embodiment of this application;
[0024] Figure 3 is a schematic diagram of the first model portion of a three-dimensional model provided in an exemplary embodiment of this application;
[0025] Figure 4 is a flowchart of a three-dimensional model data processing method provided in an exemplary embodiment of this application;
[0026] Figure 5 is a schematic diagram of the setup of the first skeleton provided in an exemplary embodiment of this application;
[0027] Figure 6 is a schematic diagram of a first model portion provided in an exemplary embodiment of this application;
[0028] Figure 7 is a schematic diagram of the parameter setting interface for the deformation control parameters of a shape change trigger provided in an exemplary embodiment of this application;
[0029] Figure 8 is a flowchart of a three-dimensional model data processing method provided in an exemplary embodiment of this application;
[0030] Figure 9 is a schematic diagram of the weight data setting for the first model portion provided in an exemplary embodiment of this application;
[0031] Figure 10 is a flowchart of a three-dimensional model data processing method provided in an exemplary embodiment of this application;
[0032] Figure 11 is a schematic diagram of a three-dimensional model provided in an exemplary embodiment of this application;
[0033] Figure 12 is a structural block diagram of a three-dimensional model data processing device provided in an exemplary embodiment of this application;
[0034] Figure 13 is a structural block diagram of a three-dimensional model data processing device provided in an exemplary embodiment of this application;
[0035] Figure 14 is a structural block diagram of a terminal provided in an exemplary embodiment of this application. Detailed Implementation
[0036] First, a brief introduction to the terms used in the embodiments of this application will be given.
[0037] 3D models are the core element in building virtual worlds. They simulate real-world objects and characters through complex geometry, texture mapping, and material properties. Through animation systems, 3D models can perform various actions, such as walking, jumping, and attacking, providing players and viewers with an immersive visual experience.
[0038] Skeleton: A skeleton is a series of interconnected virtual "bones" used to control the shape and movement of a 3D model. The skeleton of a 3D model is organized together according to a specific hierarchical structure, forming a framework similar to a biological skeleton. Each bone has a set of parameters defined to indicate its position, rotation, and scaling properties.
[0039] Rigging: This refers to defining and organizing a created skeleton, including controlling the spatial transformation properties of the bones (e.g., translation, rotation, and scaling), to make the movement of each bone in the skeleton more realistic or achieve the desired business outcome. Optionally, rigging can also implement special functions, such as follow and gaze, or linkage with mechanical devices, making animators more accurate and efficient in creating animations.
[0040] Skinning is a technique that associates the mesh of a 3D model with one or more bones. It combines the vertices of a 3D model's mesh with a skeletal system, allowing the model to deform naturally in response to bone movement. Skinning enables the skeleton to drive the 3D model to produce believable motion, defining which parts of the 3D model's mesh need to move when a given bone is animated. That is, when the bones of the 3D model move, they cause the connected model mesh (usually surface parts such as skin or clothing) to deform accordingly, thus achieving natural character movements. For example, when a character's leg bones bend, the model mesh of that leg will also bend accordingly, just like a realistic human body.
[0041] Controller: An important tool for controlling skeletal movement. Controllers can be simple rotation or position controls, or complex custom controllers used to achieve more intricate animation effects.
[0042] Spring Controller: A controller used to simulate the effect of a spring. A spring controller can add secondary dynamics to the position of any point or object.
[0043] Figure 1 shows a schematic diagram of an implementation environment provided by an exemplary embodiment of this application. The implementation environment includes: terminal 110.
[0044] Terminal 110 runs a computer program that supports 3D model data processing. Optionally, the computer program can be implemented as a motion graphics application, a modeling application, a game development application, a 3D painting application, etc., such as 3ds Max, Unity, Unreal Engine (UE), etc.
[0045] The device type of terminal 110 includes at least one of the following: game console, desktop computer, smartphone, tablet computer, e-book reader, in-vehicle terminal, extended reality (XR) device (e.g., virtual reality (VR) device, augmented reality (AR) device, mixed reality (MR) device, etc.), Moving Picture Experts Group Audio Layer III (MP3) player, Moving Picture Experts Group Audio Layer IV (MP4) player, and laptop computer. The following embodiments use a desktop computer as an example.
[0046] Indicatively, after obtaining the three-dimensional model of the first object and the corresponding model motion data, the terminal 110 imports the three-dimensional model of the first object and the model motion data into the aforementioned computer program. The computer program then creates a shape change trigger corresponding to the first model part in the three-dimensional model of the first object, thereby adjusting the deformation control parameters of the shape change trigger based on the model motion data to obtain the shape change data of the first model part.
[0047] In some embodiments, the implementation environment may further include server 120. Illustratively, terminal 110 is connected to server 120 via a wireless network or a wired network.
[0048] Server 120 includes at least one of a single server, multiple servers, a cloud computing platform, and a virtualization center. Server 120 provides background services for computer programs that support the processing of 3D model data. Optionally, server 120 undertakes the primary computing task, and terminal 110 undertakes the secondary computing task; or, server 120 undertakes the secondary computing task, and terminal 110 undertakes the primary computing task; or, server 120 and terminal 110 collaborate on computing using a distributed computing architecture.
[0049] It is worth noting that the aforementioned server 120 can be implemented as a physical server or as a cloud server in the cloud. In some embodiments, the aforementioned server 120 can also be implemented as a node in a blockchain system.
[0050] Schematic illustration: After terminal 110 uploads the 3D model of the first object and the corresponding model motion data to server 120, server 120 creates a corresponding shape change trigger for the first model part in the 3D model of the first object by calling the model data processing service. Based on the model motion data, the server controls the shape change trigger to obtain the shape change data of the first model part. Server 120 then sends the generated shape change data to terminal 110. In one example, the shape change trigger is created using a first skeleton; that is, a first skeleton is created, a shape change trigger is made for the first skeleton, and the first model part is used to skin the first skeleton, thereby establishing a binding relationship between the first model part and the shape change trigger.
[0051] Based on the above-described terminology and implementation environment, the 3D model data processing method provided in this application will be described, taking the execution of this method by a computer device as an example. This computer device can be implemented as a terminal and / or a server, as shown in Figure 2. The method includes at least one of the following steps 210 to 240. The embodiments of this application can be implemented as independent embodiments or in combination with any other embodiments, and are not limited herein.
[0052] Step 210: Obtain a three-dimensional model of the first object. The three-dimensional model includes at least one model part, and the at least one model part includes a first model part corresponding to the flexible body tissue of the first object.
[0053] The first object is implemented as a virtual object in a virtual scene, that is, an object that can move within the virtual scene. The virtual object has its own shape and volume in the three-dimensional virtual scene and occupies a portion of the space within the three-dimensional virtual scene. Optionally, the first object can be implemented as a virtual character, virtual animal, virtual plant, etc. Optionally, the aforementioned virtual scene includes game virtual scenes, animation virtual scenes, extended reality virtual scenes, etc.
[0054] A 3D model refers to a model structure constructed on a computer device and presented in a three-dimensional form. Illustratively, the 3D model of the first object is implemented as a virtual character model, a virtual animal model, etc. In some embodiments, the 3D model is indicated by model data, wherein the model data is data used to define the attribute information of the 3D model of the first object, enabling the first object to be accurately rendered and displayed in computer graphics applications. The aforementioned attribute information includes at least one of the geometry, appearance, and model behavior of the object's components.
[0055] Optionally, the model data can be implemented as at least one of mesh data, voxel data, and point cloud data.
[0056] In 3D computer graphics, a mesh is a data structure used to represent the surface of a 3D model. A mesh consists of a set of vertices, edges, and faces, which together define the geometry of an object. Optionally, the mesh cells formed by edges can be implemented as polygons such as triangles, quadrilaterals, and pentagons. In a mesh, vertices are the basic points that make up the mesh. They have coordinates (x, y, z) in 3D space, and each vertex represents a position on the mesh, serving as the smallest unit that constitutes a 3D model. Edges are line segments that connect two vertices, defining the connection between vertices and forming the basis of faces. A face is a polygon enclosed by multiple vertices and edges, i.e., the aforementioned mesh cells. In a 3D model, faces define the surface of an object, and multiple faces combined together form the complete appearance of the object.
[0057] A voxel is a pixel in three-dimensional space, similar to a pixel in a two-dimensional image. It is the basic unit of three-dimensional volume data, with each voxel occupying a cubic volume in three-dimensional space, the size of which depends on the resolution of the entire 3D model. Voxels are commonly used to represent the volume information of a 3D model in three-dimensional space and can store various data about volume, such as geometric occupancy, density, and color. Each voxel in a 3D model represented by voxel data has a definite spatial location, defined by its coordinates (x, y, z) in a three-dimensional coordinate system.
[0058] Point cloud is a method of representing 3D model data. A point cloud consists of a large number of 3D coordinate points that collectively describe the surface of an object or scene. That is, a point cloud is a collection of points formed by the spatial coordinates of each sampled point on the surface of a 3D object. Point cloud data includes the 3D coordinates (x, y, z) of the sampled points, as well as at least one additional attribute information selected from laser reflection intensity, color information, and reflection intensity.
[0059] Optionally, obtaining the three-dimensional model of the first object includes: reading model data of the three-dimensional model of the first object from the storage area of the terminal; or receiving model data of the three-dimensional model of the first object sent by the server; wherein the model data is data used to define the attributes of the three-dimensional model of the first object (e.g., at least one of the structure, appearance, size, etc. of the three-dimensional model), so that the first object can be accurately rendered and displayed in computer graphics applications.
[0060] In this embodiment, the three-dimensional model of the first object includes at least one model portion, wherein the model portion is used to indicate the parts that make up the three-dimensional model of the first object. In one example, taking the first object as a virtual character, the three-dimensional model of the first object includes a model portion corresponding to the legs, a model portion corresponding to the torso, a model portion corresponding to the head, a model portion corresponding to the arms, a model portion corresponding to the hands, a model portion corresponding to the feet, etc.
[0061] Optionally, at least one model part can be obtained by pre-dividing the three-dimensional model of the first object according to the model structure during the production process; or, at least one model part can be obtained manually after obtaining the three-dimensional model of the first object; or, at least one model part can be obtained automatically according to the binding relationship between the three-dimensional model and the model skeleton after obtaining the three-dimensional model of the first object. For example, taking the model data of the three-dimensional model as mesh data, the polygon set bound to each bone in the model skeleton is divided as a model part to obtain at least one model part.
[0062] In this embodiment, at least one model portion includes a first model portion corresponding to the flexible body tissue of the first object. Illustratively, the first model portion is used to represent the morphology and movement of the flexible body tissue.
[0063] In some embodiments, the flexible body tissue refers to the location of the first object that exhibits an elastic shaking effect during movement. Optionally, the flexible body tissue includes virtual muscles, virtual fat, virtual skin, etc., of the first object.
[0064] In one example, as shown in Figure 3, a schematic diagram of the first model part of a three-dimensional model provided in an exemplary embodiment of this application is shown. Taking the first object as a virtual character as an example, in order to closely resemble the movement effect of a real human body, it is necessary to represent the shaking effect of the muscle parts in the three-dimensional model 300 of the virtual character during the movement process. Taking the three-dimensional model 300 as an example, the first model part of the three-dimensional model 300 includes a model part 310 and a model part 320. The model part 310 is the buttocks of the virtual character, corresponding to virtual muscles or virtual fat of the buttocks, and the model part 320 is the legs of the virtual character, corresponding to virtual muscles or virtual fat of the legs.
[0065] Optionally, the first model part can be a 3D model of the first object that is pre-divided according to the model structure during the production process. For example, taking flexible body tissue as virtual muscle as an example, when creating a 3D model of a virtual character, according to the human biological structure, the virtual character is divided into multiple muscle regions, each muscle region corresponding to at least one virtual muscle, and the model parts corresponding to the multiple muscle regions in the 3D model are determined as the first model part.
[0066] In some embodiments, the division scale corresponding to the first model portion can be flexibly determined according to the application scenario. For example, taking the muscle region of the virtual character corresponding to the first model portion as an example, each muscle of the virtual character is divided into a muscle region to determine the corresponding first model portion; or, the combination of multiple muscles in each part (e.g., head, upper arm, forearm, back, thigh, etc.) is divided into a muscle region to determine the corresponding first model portion.
[0067] Optionally, the first model portion may be selected during the generation of morphological change data. Illustratively, during the generation of morphological change data, the terminal displays a 3D model of the first object, receives selection operations from the user for one or more model portions within the 3D model of the first object, and determines the first model portion based on the selection operations. For example, the user selects the first model portion from the 3D model using a selection tool.
[0068] Step 220: Invoke the shape change trigger.
[0069] In this embodiment, the first model portion is bound to a shape change trigger, which is used to control the shape change of the first model portion through deformation control parameters. That is, by adjusting the deformation control parameters of the shape change trigger, the shape change trigger can produce different elastic deformation effects. The deformation produced by the shape change trigger can drive the first model portion to undergo corresponding shape changes, thereby producing a jitter effect.
[0070] Optionally, the shape change trigger can be implemented as a spring controller, a curve controller, etc. In this embodiment, the shape change trigger is illustrated as a spring controller.
[0071] The spring controller is a controller used to simulate spring effects. The spring controller bound to the first model portion can add secondary dynamic effects to it. Specifically, the spring controller controls the first model portion to simulate the morphological changes of flexible body tissue through spring-like effects. It's important to note that the spring controller is not used to control a physical spring, but rather to control the model or skeleton to produce elastic deformation similar to a spring. Optionally, the spring controller can control the first model portion to simulate the shaking or swaying effects of flexible body tissue.
[0072] A curve controller is a controller used to simulate curve effects. By defining keyframes and curve shapes on the timeline, it controls the movement, deformation, or other attribute changes of an object. Specifically, the curve controller is used to control the first model portion to simulate the morphological changes of flexible body tissue through curve effects. Optionally, the curve controller can be used to control the first model portion to simulate the shaking or swaying effects of flexible body tissue.
[0073] Optionally, deformation control parameters are used to achieve elastic deformation, torsional deformation, etc.
[0074] Elastic deformation refers to the deformation process that occurs under the action of an external force and can return to its original shape and size when the external force is removed. In the embodiments of this application, the external force driving the elastic deformation is the force generated by the action performed by the three-dimensional model on the flexible body tissue. That is, during the movement of the three-dimensional model, the force generated by the movement causes the flexible body tissue to undergo elastic deformation. For example, during the process of raising the leg, the leg muscles undergo elastic deformation, causing the leg to exhibit a shaking effect.
[0075] Torsional deformation refers to the deformation process that occurs when subjected to a torque in the opposite direction. In the embodiments of this application, during the movement of the three-dimensional model, the force generated by the movement causes the flexible body tissues to undergo torsional deformation. For example, during body rotation, abdominal fat and muscles undergo torsional deformation, resulting in a change in the shape of the abdomen.
[0076] This illustration demonstrates the construction of a shape change trigger associated with the first model portion. Optionally, the shape change trigger can be constructed in at least one of the following ways:
[0077] The first method involves binding a first skeleton to the first model part and building a shape change trigger on the basis of the first skeleton.
[0078] To illustrate, the first model part is bound to the first skeleton, and the shape change trigger is built on the first skeleton. That is, the first model part and the shape change trigger are bound together through the first skeleton.
[0079] In a schematic manner, a first bone is created; the shape change trigger corresponding to the first bone is constructed, and the shape change trigger is used to control the first bone to produce elastic deformation according to the deformation control parameters; the first bone is bound to the first model part to obtain the bone binding data corresponding to the first model part.
[0080] In some embodiments, creating a first bone is achieved by: obtaining the bone parameters of the first bone, wherein the bone parameters include the bone start point and the bone end point of the first bone, the bone start point and the bone end point being points determined based on the flexible deformation direction and flexible deformation range of the flexible body tissue; and creating the first bone based on the bone parameters of the first bone.
[0081] Schematic illustration: the direction and range of flexible deformation of the aforementioned flexible body tissue are related to the direction of its tissue texture. In one example, when the flexible body tissue is implemented as muscle tissue, the direction of flexible deformation is related to the direction of muscle contraction, and the range of flexible deformation is related to the arrangement of muscle fibers within the muscle tissue. In another example, when the flexible body tissue is implemented as adipose tissue, the direction of flexible deformation is related to the direction of deformation of the extracellular matrix within the adipose tissue, and the range of flexible deformation is related to the structure and arrangement of the extracellular matrix within the adipose tissue. It is worth noting that the aforementioned muscle tissue and adipose tissue are virtual concepts in the 3D model; that is, when characterizing the deformation of the flexible body tissue through the deformation of the first bone, the tissue texture of the flexible body tissue in the physical world is referenced to determine the bone start point and bone end point corresponding to the first bone.
[0082] Schematic, the starting point and ending point of the first bone are two different locations associated with the first model part.
[0083] In one possible implementation, the starting point of the first bone can be implemented as a first position point in the second bone associated with the first model part, and the ending point of the first bone can be implemented as a second position point in the first model part. The first position point and the second position point are different position points.
[0084] Optionally, the first position point can be implemented as at least one of the following positions: center, center of gravity, centroid, or bone endpoint of the second bone, or any position manually selected in the second bone; the second position point can be implemented as at least one of the following positions: center, center of gravity, or centroid of the first model part, or any position manually selected in the first model part.
[0085] Optionally, the determination of the start point and end point of the first bone may include at least one of the following methods:
[0086] 1. Determine the bone start point from the second skeleton and the bone end point from the first model part by receiving a selection operation.
[0087] In some embodiments, when creating a first skeleton, a 3D model of a first object and its corresponding model skeleton are displayed. The 3D model includes a first model portion, and the model skeleton includes a second skeleton. A first selection operation is received at a first position point in the second skeleton to determine the skeleton's start point. A second selection operation is received at a second position point in the first model portion to determine the skeleton's end point. Where the selection of the skeleton's start point and end point has an order requirement, or where, before receiving the first or second selection operation, it is specified whether the selected position point corresponds to the skeleton's start point or end point, the operation methods of the first and second selection operations may be the same or different. Alternatively, if the operation methods of the first and second selection operations are different, then the operation method of the selected position point corresponds to the selection operation to determine whether it belongs to the skeleton's start point or end point.
[0088] 2. After indicating the first model part to be bound, automatically identify the first position point in the second bone associated with the first model part as the bone start point of the first bone, and automatically identify the second position point in the first model part as the bone end point of the first bone.
[0089] In some embodiments, when creating the first bone, a three-dimensional model of the first object and the corresponding model skeleton are displayed, a selection operation on the first model part in the three-dimensional model is received, the second bone bound to the first model part is determined according to the model skeleton, the first position point in the second bone associated with the first model part is automatically identified as the bone start point of the first bone, and the second position point in the first model part is automatically identified as the bone end point of the first bone.
[0090] Optionally, the automatic identification of the first and second position points can be achieved through preset identification rules. For example, if there are predefined identification rules that indicate when creating the first bone between the second bone and the first model part, the bone center in the second bone is taken as the bone start point of the first bone, and the centroid of the first model part is taken as the bone end point of the first bone.
[0091] Optionally, the automatic identification of the first and second position points can be achieved through a pre-trained skeleton creation model. In some embodiments, the skeleton creation model is a machine learning model trained using sample model data labeled with bone start points and bone end points. Illustratively, the sample data includes sample models and sample skeletons, as well as sample bones bound between the sample models and the sample skeletons. The first predicted position point in the sample skeleton model and the second predicted position point in the sample model are identified using the skeleton creation model to be trained. Thus, based on the predicted bones formed between the first and second predicted position points, and the sample bones, the skeleton creation model to be trained is trained to obtain the aforementioned skeleton creation model. The position points in the first model portion and the second bone are analyzed using the skeleton creation model, and a first position point used as a bone start point is determined from the second bone, and a second position point used as a bone end point is determined from the first model portion.
[0092] The correspondence between the first model part and the second skeleton is pre-set during the production process of the three-dimensional model and the model skeleton of the first object. That is, during the production process of the three-dimensional model of the first object, when setting the model skeleton for the three-dimensional model, a binding relationship is established between the second skeleton and the first model part in the model skeleton. This allows the second skeleton to generate corresponding movement when the model skeleton is controlled to move.
[0093] Optionally, the bone parameters of the first bone also include the bone structure, which includes the bone length and bone hierarchy. The bone length indicates the distance between the start and end points of the first bone. Optionally, the bone length can be manually configured by the animator or automatically identified based on the positions of the indicated start and end points. The bone hierarchy indicates the superior and / or inferior bones of the first bone. The superior bone is the bone that controls the first bone, and the inferior bone is the bone that the first bone has control over. In this embodiment, the superior bone of the first bone is set as the second bone associated with the first model portion. Optionally, the hierarchical relationship between the second and first bones can be manually set by the animator or automatically generated when binding the first and second bones.
[0094] To illustrate, after determining the bone parameters of the first bone, a virtual bone corresponding to the bone structure indicated by the bone parameters is generated in the 3D space corresponding to the 3D model, based on the bone start point and bone end point indicated by the bone parameters. This virtual bone serves as the first bone. For example, if the coordinates of the bone start point are (x1, y1, z1) and the coordinates of the bone end point are (x2, y2, z2), and the bone structure indicates that the required first bone is a straight line structure, then the created first bone is a line segment from the coordinate point (x1, y1, z1) to the coordinate point (x2, y2, z2).
[0095] That is, by instructing the skeletal parameters of the first bone to create the first bone, the accuracy of virtual bone creation is improved, thereby improving the accuracy of controlling the morphological changes of flexible body tissues based on virtual bones.
[0096] To illustrate, the process of constructing a shape change trigger based on the first skeleton is as follows: obtain the first and second bone points of the first skeleton, which are different positions in the first skeleton; use the first bone point as the deformation fixed point and the second bone point as the deformation motion point to construct the shape change trigger. The deformation fixed point is the position where the first skeleton remains relatively stationary with respect to the overall framework of the 3D model under the control of the shape change trigger, and the deformation motion point is the position where the first skeleton is displaced relative to the overall framework of the 3D model under the control of the shape change trigger.
[0097] In one example, taking the shape change trigger as a spring controller, the deformation motion point is the position where the first bone remains relatively stationary with respect to the overall frame of the 3D model when simulating spring movement under the control of the spring controller, and the deformation motion point is the position where the first bone undergoes displacement relative to the overall frame of the 3D model when simulating spring movement under the control of the spring controller.
[0098] Optionally, the first bone point is implemented as the bone start point of the first bone, and the second bone point is implemented as the bone end point of the first bone. That is, the bone start point and bone end point of the first bone are obtained, and the bone start point is used as the deformation fixation point and the bone end point is used as the deformation motion point to construct a shape change trigger.
[0099] Optionally, the first bone point is implemented as the bone start point of the first bone, and the second bone point is implemented as the bone midpoint of the first bone. That is, the bone start point and bone midpoint of the first bone are obtained, and the bone start point is used as the deformation fixation point, and the bone midpoint is used as the deformation motion point to construct a shape change trigger.
[0100] Optionally, the first and second bone points can also be any two different locations in the first bone selected manually, without specific limitations.
[0101] That is, by setting the first bone point and the second bone point respectively to simulate the fixed end and the elastic deformation end of the spring, the performance effect of the elastic deformation achieved by the first bone is improved.
[0102] Optionally, when the shape change trigger is implemented as a spring controller, the deformation fixation point of the spring controller is one of the endpoints of the spring simulated by the spring controller; the deformation motion point includes another endpoint of the spring simulated by the spring controller that is different from the endpoint where the deformation fixation point is located, or other position points other than the endpoint where the deformation fixation point is located (e.g., intermediate position points).
[0103] Optionally, the first object includes a character object. In one example, when the flexible body tissue includes leg tissue, the creation direction of the first bone corresponds to the extension direction of the leg muscles, wherein the distance between the first bone point and the buttock tissue of the character object is less than the distance between the second bone point and the buttock tissue. In another example, when the flexible body tissue includes buttock tissue, the buttock tissue includes left and right buttock tissues adjacent to each other at a first adjacent point. The creation direction of the first bone corresponding to the left buttock tissue corresponds to the direction of the line connecting the first and second adjacent points. The second adjacent point is the adjacent point between the left buttock tissue and the leg tissue, wherein the distance between the first bone point and the first adjacent point is less than the distance between the second bone point and the first adjacent point. That is, by aligning the creation direction of the bones with the extension direction of the leg muscles and setting the bone points according to the structure of the buttock tissue, the physiological structure of the human body can be simulated more accurately, thereby making the animation effect of the character's movements more realistic and natural.
[0104] Optionally, the first object includes an animal object. In one example, when the flexible body tissue includes cheek tissue, the creation direction of the first bone corresponds to the outward convex direction of the cheek tissue, wherein the outward convex distance of the first bone point is less than the outward convex distance of the second bone point. In another example, when the flexible body tissue includes belly tissue, the creation direction of the first bone corresponds to the outward convex direction of the belly tissue, wherein the outward convex distance of the first bone point is less than the outward convex distance of the second bone point. In yet another example, when the flexible body tissue includes antennal tissue, the antennal tissue grows at a first external surface position of the animal object, and the creation direction of the first bone corresponds to the growth direction of the antennal tissue, wherein the distance between the first bone point and the first external surface position is less than the distance between the first bone point and the first external surface position. That is, by aligning the creation direction of the bones with the outward convex or growth direction of flexible tissues such as cheeks, belly, and antennae, the physiological structure of the animal can be simulated more accurately, thereby making the animation effect of animal movements more realistic and natural.
[0105] In some embodiments, the process of binding the first model part to the first bone is implemented as follows: the first model part of the 3D model is used to skin the first bone, and a binding relationship is established between the first bone and the first model part. For example, when the 3D model is implemented through a mesh, a binding relationship is established between the first bone and one or more model vertices in the mesh; or, for example, when the 3D model is implemented through a point cloud, a binding relationship is established between the first bone and one or more 3D coordinate points in the point cloud.
[0106] The second method involves directly constructing a morphological change trigger on the skeleton of the 3D model that is associated with the first model part.
[0107] In a schematic manner, the model skeleton of the 3D model is obtained, which includes a second bone corresponding to the first model part. The model skeleton is the skeleton data configured during the model making process of the 3D model. The model skeleton is used to drive the 3D model to move (e.g., to realize displacement, rotation and scaling). A third position point in the second bone and a fourth position point in the first model part are determined. The third position point is used as the deformation fixed point and the fourth position point is used as the deformation motion point to construct a shape change trigger.
[0108] The correspondence between the first model part and the second skeleton is pre-set during the production process of the three-dimensional model and the model skeleton of the first object. That is, during the production process of the three-dimensional model of the first object, when setting the model skeleton for the three-dimensional model, a binding relationship is established between the second skeleton and the first model part in the model skeleton. This allows the second skeleton to generate corresponding movement when the model skeleton is controlled to move.
[0109] The deformation fixed point is the position where the shape change trigger remains relatively stationary with respect to the overall framework of the 3D model, while the deformation motion point is the position where the shape change trigger moves relative to the overall framework of the 3D model.
[0110] Optionally, when the shape change trigger is implemented as a spring controller, the deformation fixed point corresponding to the spring controller is one of the endpoints of the spring simulated by the spring controller; the deformation motion point includes another endpoint of the spring simulated by the spring controller that is different from the endpoint where the deformation fixed point is located, or other position points other than the endpoint where the deformation fixed point is located (e.g., intermediate position points).
[0111] Optionally, the third location point can be at least one of the following: the center, center of gravity, center of mass, or bone endpoint of the second bone; or it can be any location manually selected within the second bone. Similarly, the fourth location point can be at least one of the following: the center, center of gravity, or center of mass of the first model part; or it can be any location manually selected within the first model part. The third and fourth location points are different locations.
[0112] In some embodiments, the second bone in the model skeleton of the 3D model is used as the first bone. The second bone is the bone in the model skeleton that corresponds to the first model part. That is, a shape change trigger is constructed on the second bone in the model skeleton. The implementation method of constructing the shape change trigger on the second bone is the same as the implementation method of constructing the shape change trigger on the first bone, and will not be described in detail here.
[0113] In one example, taking the first model part as the buttocks model of a virtual character as an example, the deformation fixation point of the shape change trigger can be set on the pelvic bone corresponding to the buttocks model part (this pelvic bone is a bone in the virtual character's model skeleton), and the deformation motion point is set on the buttocks model part. This allows the movement of the virtual character's 3D model to be controlled by controlling the virtual character's model skeleton, with the movement generated by the pelvic bone transmitting "force" to the shape change trigger. Driven by the received "force," the shape change trigger undergoes elastic deformation, thereby causing the buttocks model part to produce a corresponding shaking effect (for example, the buttocks model part shakes up and down during a jump, representing the shaking effect of the buttock muscles and fat during a jump). When the shape change trigger is created on the first bone, when the shape change trigger receives the "force" generated by the movement of the pelvic bone, it drives the first bone to undergo elastic deformation, thereby causing the buttocks model part bound to the first bone to produce a corresponding shaking effect.
[0114] In another example, taking the thigh model of a virtual character as the first model part, the deformation fixation point of the shape change trigger can be set on the thigh bone corresponding to the thigh model part (this thigh bone is a bone in the virtual character's model skeleton), and the deformation motion point is set on the thigh model part. This allows the thigh bone to transmit "force" to the shape change trigger when the virtual character's 3D model is moved by controlling the model skeleton. Driven by this received "force," the shape change trigger undergoes elastic deformation, causing the thigh model part to produce a corresponding shaking effect (for example, during leg lifting, the thigh model part shakes up and down, representing the shaking effect of the thigh muscles during the leg lifting action). When the shape change trigger is created on the first bone, when it receives the "force" generated by the thigh bone's movement, it drives the first bone to undergo elastic deformation, thereby causing the thigh model part bound to the first bone to produce a corresponding shaking effect.
[0115] In another example, taking the chest model of a virtual character as the first model part, the deformation fixation point of the shape change trigger can be set on the sternal bone corresponding to the chest model part (this sternal bone is a bone in the virtual character's model skeleton), and the deformation motion point is set on the chest model part. This allows the movement of the virtual character's 3D model to be controlled by controlling the virtual character's model skeleton, with the movement of the sternal bone transmitting "force" to the shape change trigger. Driven by the received "force," the shape change trigger undergoes elastic deformation, causing the chest model part to produce a corresponding shaking effect (for example, during running, the chest model part shakes up and down, representing the shaking effect of the chest during running). When the shape change trigger is created on the first bone, when it receives the "force" generated by the movement of the sternal bone, it drives the first bone to undergo elastic deformation, thereby causing the chest model part bound to the first bone to produce a corresponding shaking effect.
[0116] The third method involves selecting at least two model vertices in the first model part of the 3D model to construct a morphological change trigger associated with the first model part.
[0117] In a schematic way, the first model vertex is determined as the deformation fixed point from the model vertices of the first model part, and the second model vertex is determined as the deformation motion point to construct the shape change trigger.
[0118] In this context, the deformation fixed point is the position where the shape change trigger remains relatively stationary relative to the overall framework of the 3D model, while the deformation motion point is the position where the shape change trigger undergoes displacement relative to the overall framework of the 3D model. The first model vertex and the second model vertex are model vertices located at different positions within the first model section.
[0119] Optionally, when determining the first model vertex and the second model vertex, at least one of the following methods may be used:
[0120] 1. When configuring the morphological change trigger, the first model vertex and the second model vertex are determined from the first model part by receiving the selection operation.
[0121] In some embodiments, when configuring a shape change trigger, at least two model vertices of a first model portion are displayed, a first selection operation is received from the at least two model vertices to determine the first model vertex, and a second selection operation is received from the at least two model vertices to determine the second model vertex. Where the selection of the first and second model vertices has an order requirement, or where, before receiving the first or second selection operation, it is specified whether the selected model vertex corresponds to a deformation fixed point or a deformation moving point, the operation methods of the first and second selection operations are the same or different. Alternatively, if the operation methods of the first and second selection operations are different, then the model vertex corresponding to the selection operation is determined to be a deformation fixed point or a deformation moving point based on the operation method of the selection operation.
[0122] 2. When configuring the shape change trigger, at least two model vertices in the first model part are identified by the pre-trained vertex recognition model, and the first model vertex and the second model vertex are determined from the at least two model vertices.
[0123] In some embodiments, the vertex recognition model is a machine learning model trained on sample model data labeled with deformation fixed points and deformation moving points. Illustratively, the sample data includes a sample hip model, which is bound to a shape change trigger. The shape change trigger is bound to a first sample vertex and a second sample vertex in the sample hip model, where the first sample vertex serves as a deformation fixed point and the second sample vertex serves as a deformation moving point. The sample vertex recognition model to be trained identifies at least two sample vertices in the sample hip model, determining the first predicted vertex as the deformation fixed point and the second predicted vertex as the deformation moving point. Thus, based on the first vertex distance between the first sample vertex and the first predicted vertex, and the second vertex distance between the second sample vertex and the second predicted vertex, the sample vertex recognition model is trained to obtain the aforementioned vertex recognition model. The vertex recognition model analyzes the model vertices in the first model portion, determining the first model vertex used as a deformation fixed point and the second model vertex used as a deformation moving point from the first model portion.
[0124] Optionally, after determining the first model vertex and the second model vertex, a supporting skeleton is constructed between the first model vertex and the second model vertex, and the shape change trigger is bound to the supporting skeleton. The first model part is controlled by the shape change trigger through the supporting skeleton as a medium.
[0125] Optionally, the starting point of the supporting skeleton is implemented as a first model vertex, and the ending point of the supporting skeleton is implemented as a second model vertex; or, the starting point of the supporting skeleton is implemented as a second model vertex, and the ending point of the supporting skeleton is implemented as a first model vertex.
[0126] It is worth noting that the above configuration of the shape change trigger is only an illustrative example, and the embodiments of this application do not limit it. In addition, the model vertices used when configuring the shape change trigger can also be implemented as point cloud positions in point cloud data, or as pixel blocks, and the embodiments of this application do not limit it either.
[0127] Step 230: Obtain model motion data.
[0128] The model motion data is used to control the movement of at least one model part so that the first object performs a first action.
[0129] In some embodiments, the model motion data includes at least one of the following: motion animation corresponding to the first motion, motion control interaction data, motion parameters, and second skeletal motion data.
[0130] The motion animation is used to indicate the animation data corresponding to the first object when a specified first action is performed. This animation data includes image data (e.g., image frames, resolution, color depth, etc.), time data (e.g., animation duration, timestamps corresponding to each action node of the first action, timeline, etc.), and motion data (e.g., keyframes, motion curves, etc., where keyframes define the position, rotation, and scaling attributes of the first object in the motion animation; the computer device automatically interpolates and generates intermediate frames based on the keyframes to create smooth motion of the 3D model). In some embodiments, the motion animation is animation data obtained by an animator through drawing; or, the motion animation is animation data extracted from an animated work; or, the motion animation is data obtained by style conversion of a filmed video.
[0131] Motion control interaction data is used to indicate user input or event triggering events involved in the implementation of the first action by the 3D model of the first object. For example, user input includes operation inputs that trigger the first action, operation inputs that control the magnitude of the action, operation inputs that control the duration of the first action, operation inputs that select the action interaction object for the first action, etc.
[0132] Motion parameters are used to indicate the parameters involved when the 3D model of the first object performs a first action. Optionally, motion parameters include action execution duration, motion path, action type, and associated bones related to the first action. The associated bones are bones used to control and implement the first action; that is, controlling the associated bones enables the 3D model of the first object to perform the first action. In some embodiments, motion parameters may be configured by the animator when designing the 3D model of the first object to perform the first action; or, motion parameters may be obtained by identifying image frames provided in the motion animation.
[0133] The second skeletal motion data is used to indicate the motion of at least one candidate bone bound to the 3D model when the first object performs the first action. Optionally, the at least one candidate bone can be implemented as all the bones in the 3D model, or the at least one candidate bone can be implemented as the aforementioned associated bones. In some embodiments, the second skeletal motion data can be data generated when at least one candidate bone of the 3D model is driven by the motion parameters of the first action.
[0134] Step 240: Based on the model action data, assign values to the deformation control parameters through the shape change trigger, and control the shape change of the first model part during the execution of the first action to obtain shape change data.
[0135] In other words, the morphological change trigger assigns values to the deformation control parameters based on the model's motion data, thereby controlling the morphological changes of the first model part during the first object's execution of the first action, generating morphological change data. This morphological change data is used to represent the morphological changes of flexible body tissues during the first object's execution of the first action.
[0136] Optionally, the morphological change data includes the skeletal animation of the first bone, wherein the skeletal animation of the first bone is used to indicate the animation data corresponding to the first bone when the first object performs a specified first action. Optionally, the animation data corresponding to the first bone includes image data (e.g., image frames, resolution, color depth, etc.), time data (e.g., animation duration, timestamps corresponding to each motion node of the first bone, timeline, etc.), and motion data (e.g., keyframes, motion curves, etc., wherein keyframes are used to define the position, rotation, and scaling attributes of the first bone in the skeletal animation, and the computer device automatically interpolates intermediate frames based on the keyframes to create smooth motion of the first bone).
[0137] Optionally, the morphological change data also includes the bone data of the first bone, wherein the bone data of the first bone includes at least one of the following: the binding relationship between the first bone and the first model part, the morphological change trigger corresponding to the first bone, and the bone parameters of the first bone.
[0138] Optionally, the morphological change data may also include at least one of the model data of the three-dimensional model of the first object and the model action data corresponding to the first action.
[0139] In some embodiments, morphological change data is generated by deformation control parameters for a morphological change trigger. Illustratively, parameter assignment data for at least one deformation control parameter corresponding to model motion data is obtained. This at least one deformation control parameter expresses the motion characteristics or body tissue characteristics of a flexible body tissue performing a first action. Specifically, it controls the deformation effect of the first skeleton under the influence of the first action, causing the first model portion bound to the first skeleton to produce a vibration corresponding to the deformation effect. The parameter assignment data for the at least one deformation control parameter is input to the morphological change trigger, obtaining the output data of the morphological change trigger as the first skeleton motion data. The first skeleton motion data indicates the motion of the first skeleton when the first object performs the first action. The first model portion is controlled according to the first skeleton motion data to obtain the morphological change data of the first model portion.
[0140] In some embodiments, taking a shape change trigger implemented as a spring controller as an example, the deformation control parameters corresponding to the spring controller may optionally include at least one of the following parameters:
[0141] 1. Mass parameters.
[0142] The mass parameter indicates the amplitude of the jitter of the first skeleton under the control of the spring controller. Illustratively, the mass parameter simulates the "mass" of the flexible body tissue corresponding to the first skeleton, thereby affecting the inertia of the flexible body tissue when the first object performs the first action, and thus simulating the amplitude of the jitter of the flexible body tissue under the influence of the first action.
[0143] In one example, the higher the value of the mass parameter of the spring controller, the greater the maximum distance of the jitter corresponding to the flexible body tissue and the longer the recovery time; conversely, the lower the value, the smaller the maximum distance of the jitter corresponding to the flexible body tissue and the shorter the recovery time.
[0144] In other words, by simulating the mass of flexible body tissue through mass parameters, the inertia and elastic behavior of flexible body tissue with mass in the physical world can be more realistically reflected, improving the animation effect of the generated animation. Furthermore, the mass parameters enable precise control over the amplitude of jitter, enhancing the flexibility of animation production.
[0145] 2. Resistance parameter (Drag).
[0146] The drag parameter indicates the attenuation of the first bone's movement under the control of the spring controller. Illustratively, the drag parameter indicates the air friction of the flexible body tissue corresponding to the first bone during simulated spring movement, used to counteract the energy of the first bone's rebound during simulated spring movement, thereby controlling the attenuation of the vibration of the flexible body tissue under the influence of the first movement.
[0147] In one example, the higher the resistance parameter of the spring controller, the smaller the vibration rebound of the flexible body tissue, the stronger the resistance, and the gentler the recovery effect; conversely, the greater, faster, and longer the vibration rebound of the flexible body tissue.
[0148] In other words, by simulating the air friction of flexible body tissue during simulated spring motion using drag parameters, we can more realistically reflect the vibration decay of flexible body tissue over time when it undergoes elastic deformation in the physical world, thus improving the animation effect of the generated animation. Furthermore, by using drag parameters to achieve precise control over the vibration rebound force, we can enhance the flexibility of animation production.
[0149] 3. Tension parameter.
[0150] The tension parameter indicates the stiffness of the first skeleton as it deforms under the control of the spring controller. Illustratively, the tension parameter simulates the stiffness of the spring when the first skeleton moves in a simulated spring.
[0151] In one example, the higher the value of the tension parameter of the spring controller, the tighter the simulated spring and the more stable the movement of the simulated flexible body tissue; conversely, the more relaxed the simulated spring, the closer it is to a soft rubber band or rope, and the freer the movement of the simulated flexible body tissue.
[0152] In other words, by simulating the stiffness of flexible body tissues when deforming during simulated spring motion using tension parameters, the softness of flexible body tissues in the physical world can be more realistically reflected, improving the animation effect of generated animations. Furthermore, the tension parameters enable precise control over the softness of flexible body tissues, enhancing the flexibility of animation production.
[0153] 4. Damping parameters.
[0154] The damping parameter indicates the rate at which the first bone's movement decays under the control of the spring controller. Illustratively, the damping parameter simulates the rate at which the spring stops vibrating during the simulated spring's movement; that is, the damping parameter controls the rate at which the first bone's movement decays.
[0155] In one example, the higher the value of the damping parameter of the spring controller, the smoother the movement of the flexible body tissue and the less jitter; conversely, the more violent the movement of the flexible body tissue and the more jitter.
[0156] Among them, the damping parameter is similar to the resistance parameter, but the effect is more subtle. When the value of the damping parameter is 0, the flexible body tissue is still affected by the resistance parameter and will not appear as a state without resistance. When the value of the damping parameter increases, the damping sensation increases, and compared with the resistance parameter, the slow changes of the flexible body tissue are more gentle.
[0157] In other words, by simulating the degree of deformation of flexible body tissue during simulated spring motion using damping parameters, we can more realistically reflect the different shaking effects exhibited by different types of flexible body tissue in the physical world under the same action, thus improving the animation effect of the generated animation; and by achieving precise control over the type of flexible body tissue through damping parameters, we can enhance the flexibility of animation production.
[0158] 5. Axial magnification parameter.
[0159] The axial magnification parameter is used to indicate the weight of the shaking amplitude of the first bone in at least one axial direction.
[0160] In some embodiments, the axial magnification parameters include X-axis magnification parameters (X Effect), Y-axis magnification parameters (Y Effect), and Z-axis magnification parameters (Z Effect).
[0161] In one example, the higher the value of the axial magnification parameter of the spring controller, the more significant the movement of the flexible body tissue in the corresponding axis; conversely, the weaker the movement of the flexible body tissue in the corresponding axis.
[0162] In other words, by simulating the morphological changes of flexible body tissue in different directions when simulating spring motion using the axial magnification parameter, the different shaking effects of different actions on flexible body tissue in various directions in the physical world can be more realistically reflected, thus improving the animation effect of the generated animation; and by achieving precise control over the morphological changes of flexible body tissue in different directions using the axial magnification parameter, the flexibility of animation production can be improved.
[0163] In some embodiments, the motion generated by the bone termination point corresponding to the deformation motion point in the first bone under the influence of the first action includes motion information such as initial shaking frequency, initial motion speed, initial shaking amplitude, motion direction, and shaking decay speed.
[0164] Regarding the initial jitter frequency: Since the mass parameter and tension parameter together determine the natural frequency of the spring simulated by the first skeleton, the initial jitter frequency of the motion generated by the bone termination point corresponding to the first skeleton under the influence of the first action is determined by the aforementioned mass parameter and tension parameter.
[0165] Regarding the initial motion velocity: When the bone termination point corresponding to the first bone begins to vibrate under the initial disturbance given by the first action, its corresponding initial motion velocity is determined by the natural frequency and the disturbance given by the first action. For example, when the initial disturbance given by the first action is the initial displacement, the initial velocity of the bone termination point's vibration is determined by the natural frequency determined by the mass parameter and the tension parameter, as well as the initial displacement.
[0166] Regarding the initial jitter amplitude: Since the tension parameter determines the magnitude of the elastic force generated by the spring simulated by the first bone under a unit deformation, the bone termination point corresponding to the first bone begins to vibrate under the initial disturbance given by the first action. The corresponding initial jitter amplitude is determined by the tension parameter and the initial deformation generated by the first action on the first bone. For example, when the initial disturbance given by the first action is the initial displacement, the initial deformation can be indicated by the initial displacement. Then, the initial jitter amplitude of the bone termination point vibrating is determined by the tension parameter and the initial displacement.
[0167] Regarding the direction of motion: the direction of motion of the first bone is determined by the direction of the initial displacement corresponding to the first action.
[0168] Regarding the vibration decay rate: During the vibration process under the influence of the first movement, the vibration decay rate of the bone termination point corresponding to the first bone is jointly determined by the resistance parameter and the damping parameter. That is, the vibration decay rate is adjusted by controlling the resistance parameter and the damping parameter to match the shape change requirements of the first model part. For example, when the flexible body tissue is realized as a muscle area, parameter group A (including damping parameter A and resistance parameter A) is set, and when the flexible body tissue is realized as a fat area, parameter group B (including damping parameter B and resistance parameter B) is set. The parameter value of parameter group A is greater than the parameter value of parameter group B, thus showing that the vibration decay rate of the model part corresponding to the fat area is slower than that of the model part corresponding to the muscle area, thereby reflecting the "firmness" of muscle relative to fat.
[0169] In some embodiments, after obtaining the motion information corresponding to the bone termination point of the first bone through the above deformation control parameters, the motion information is weighted by the axial ratio parameter to obtain at least one axial motion information in an axial direction, and the motion process of the first bone simulating the spring is represented by the at least one axial motion information in an axial direction.
[0170] In the above illustrative description of deformation control parameters, the deformation motion point of the spring controller is set at the bone termination point of the first bone. It is worth noting that the deformation motion point of the spring controller can also be set at other bone positions in the first bone (e.g., the middle position). The influence of the deformation control parameters on the movement of the first bone is determined by the specific position of the deformation motion point of the spring controller on the first bone. The above content is only used as an example of setting the deformation motion point of the spring controller at the bone termination point of the first bone, and does not limit the specific position of the deformation motion point of the spring controller on the first bone.
[0171] In summary, to represent the morphological changes of the flexible body tissue in the corresponding 3D model as the first object performs the first action, the morphological changes of the flexible body tissue are achieved through the model motion data corresponding to the first action and the morphological change triggers bound to the first model part. Specifically, in at least one model part participating in the execution of the first action, a morphological change trigger is set for the first model part corresponding to the flexible body tissue. During the execution of the first action, the 3D model experiences deformation caused by the first action, which in turn causes the first model part to produce a shaking effect. This results in a morphological change associated with the shaking effect, realizing the dynamic shaking effect of the flexible body tissue during the execution of the first action. This approach reduces the cost and workload of 3D model data processing while maintaining the realism of the 3D model's representation. For example, when the flexible body tissue is leg muscle, by calling the morphological change trigger to control the leg muscle to produce realistic morphological changes when performing the first action (e.g., lifting the leg), the model part corresponding to the leg muscle produces a corresponding motion effect, improving the realism of the 3D model's representation.
[0172] In some optional embodiments, a first skeleton is bound to the first model part, and a corresponding shape change trigger is constructed for the first skeleton so that the movement of the first skeleton under the influence of the first action is controlled by the shape change trigger, thereby the first skeleton drives the movement of the first model part, thus showing the shape change of the first model part during the process of the three-dimensional model performing the first action.
[0173] Please refer to Figure 4, which shows a flowchart of a three-dimensional model data processing method provided in an exemplary embodiment of this application. The method is illustrated by an example of it being executed by a computer device, which can be implemented as a terminal and / or a server. The method includes at least one step from steps 410 to 480. Embodiments of this application can be implemented as independent embodiments or in combination with any other embodiments, and are not limited herein.
[0174] Step 410: Obtain a three-dimensional model of the first object. The three-dimensional model includes at least one model part, and the at least one model part includes the first model part corresponding to the flexible body tissue of the first object.
[0175] In this embodiment of the application, the three-dimensional model of the first object includes at least one model portion, wherein the model portion is used to indicate the parts that make up the three-dimensional model of the first object.
[0176] Optionally, the first model part can be determined based on the component type of the model part. Illustratively, the component types corresponding to at least one model part are obtained, and the model part whose component type belongs to a specified component type is determined as the first model part.
[0177] Optionally, the component type includes component types divided according to the body location to which the model part belongs, such as head type, torso type, leg type, arm type, foot type, hand type, etc.; Optionally, the component type includes component types divided according to the flexible body tissue corresponding to the model part, such as muscle area type, fat area type, bone tissue area type, organ area type, etc.
[0178] In a schematic representation, the 3D model is pre-divided into multiple model parts, and the component types corresponding to each model part are labeled.
[0179] In one example, taking the component types as muscle region type, fat region type, bone tissue region type, and organ region type as an example, since the model component of fat region type is more susceptible to motion and produces a shaking effect, while the component of bone tissue region type is less susceptible to motion and produces a shaking effect, the specified model component used to filter the first model component can include muscle region type and fat region type.
[0180] In some embodiments, after obtaining the three-dimensional model of the first object, the shape of a portion of the model in the three-dimensional model of the first object is modified to ensure that the volume change of the model portion when the three-dimensional model performs the first action conforms to the change effect of flexible body tissue in the real world.
[0181] Schematic, at least one second model part is determined from at least one model part, wherein the second model part is a model part in the three-dimensional model that participates in performing the first action; a third skeleton is bound to at least one second model part, wherein the third skeleton is used to control the volume change of the second model part when the three-dimensional model performs the first action.
[0182] In some embodiments, the second model portion may be a model portion that participates in the first action, pre-divided according to the model structure during the process of creating the model action data for the first action. For example, when the first action is implemented as a running action, the second model portion includes the chest cavity portion and limb portions of the three-dimensional model.
[0183] In some embodiments, the second model portion may be selected during the generation of morphological change data. Illustratively, during the generation of morphological change data, the terminal displays a 3D model of a first object, receives a user's selection operation on a model portion within the 3D model of the first object, and determines the second model portion based on the selection operation. For example, the user selects the second model portion from the 3D model using a selection tool.
[0184] Optionally, the second model part is the same as the first model part; or, the second model part is a subset of the first model part; or, the first model part is a subset of the second model part.
[0185] In a schematic way, the third skeleton is implemented as an auxiliary skeleton when the three-dimensional model performs the first action. An auxiliary skeleton is a structure used to help shape the form of the first object, focusing on playing a supporting and guiding role in shaping the external form of the three-dimensional model.
[0186] Optionally, the aforementioned third skeleton can be implemented as a series of connected line segments and / or meshes, without limitation.
[0187] In some embodiments, the process of modifying the second model portion using a third skeleton includes: creating a third skeleton by setting its skeleton parameters, including the skeleton start point, skeleton end point, and skeleton structure; setting the skeleton position of the third skeleton in the 3D model according to the volume change required by the second model portion during the execution of the first action; and skinning the third skeleton using the second model portion of the 3D model to establish a binding relationship between the third skeleton and the second model portion. The method of skinning the third skeleton using the second model portion is the same as the method of skinning the first skeleton using the first model portion, and will not be described in detail here.
[0188] In one example, taking the first action as a leg-raising motion, the second model consists of the virtual character's hip and thigh models. In a real-world scenario, when the leg-raising motion is performed, the muscles corresponding to the thigh and hip models need to contract accordingly. There is also stretching at the junction between the thigh and hip models. Therefore, a third skeleton is used to represent the contraction effect of the muscles corresponding to the thigh and hip models, as well as the stretching effect at the junction between them. This allows the second model bound to the third skeleton to exhibit the morphological changes after muscle contraction and the morphological changes of coordinated limb movements.
[0189] By using a third skeleton to correct the shape of the second model part, it is possible to ensure that the model parts involved in the first action of the 3D model conform to the action execution effect in the real world, thereby improving the realism of the model and making it visually closer to real-world creatures. Furthermore, shape correction can also ensure the consistency of shape changes between model parts during movement. For example, when performing a leg-raising action, the shape changes of the buttock model part and the junction between the buttock model part and the thigh model part are coordinated with the movement of the thigh model part, thus ensuring the naturalness and continuity of the 3D model in motion.
[0190] Step 420: Create the first skeleton.
[0191] In this embodiment of the application, a first skeleton is created for the first model part. The creation process of the first skeleton is implemented by setting the skeleton parameters of the first skeleton to create the first skeleton. The skeleton parameters include the skeleton start point, the skeleton end point and the skeleton structure of the first skeleton.
[0192] Optionally, a first bone can be created for the first model portion; or, multiple first bones can be created for the first model portion.
[0193] In some embodiments, the starting point of the first bone can be implemented as a bone point in the skeleton of the three-dimensional model that drives the movement of the first model part; the ending position of the first bone can be implemented as a specified position of the first model part.
[0194] Optionally, the specified location can be implemented as at least one of the following: the center, center of gravity, centroid, etc. of the first model part.
[0195] In one example, taking the creation of a first bone for a first model part as an example, the shaking effect of the first model part is controlled by a single bone. As shown in Figure 5, it illustrates a schematic diagram of the setting of the first bone provided in an exemplary embodiment of this application. The three-dimensional model of the first object includes a first model part 500 (in this example, the first model part 500 is implemented as a buttock model part). A first bone 510 is created between points A 501 and B 502 in the first model part 500, where point A 501 represents the muscle centroid of the first model part 500, and point B 502 represents the pelvis of the three-dimensional model. The pelvis moves freely in the virtual world space, thereby causing the muscles corresponding to the first model part 500 to produce motion animation in various directions.
[0196] Step 430: Construct the morphological change trigger corresponding to the first bone.
[0197] The shape change trigger is used to control the elastic deformation of the first skeleton according to deformation control parameters. In one example, the shape change trigger is implemented as a spring controller, which controls the first skeleton to simulate spring movement. A spring controller is a controller used to simulate spring effects. A spring controller can add secondary dynamic effects to the position of any point or object. In this embodiment, the spring controller is used to control the movement of the first skeleton to drive the first model part to achieve a spring-like effect.
[0198] To illustrate, the process of constructing a shape change trigger based on the first skeleton is as follows: obtain the starting point and ending point of the first skeleton; use the starting point as the deformation fixation point and the ending point as the deformation movement point to construct the shape change trigger, where the deformation fixation point is the position where the first skeleton remains relatively stationary under the control of the shape change trigger, and the deformation movement point is the position where the first skeleton is displaced under the control of the shape change trigger.
[0199] Step 440: Bind the first bone to the first model part to obtain the bone binding data corresponding to the first model part.
[0200] In this embodiment of the application, a first bone is bound to the first model part in the three-dimensional model. The binding process of the first bone is implemented as follows: the first bone is skinned using the first model part of the three-dimensional model, the binding relationship between the first bone and the first model part is established, and the bone binding data is obtained. For example, when a 3D model is implemented using a mesh, a binding relationship is established between the first skeleton and the model vertices in the mesh. These model vertices are vertices in the set of vertices corresponding to the first model part within the mesh of the 3D model, possessing coordinates (x, y, z) in 3D space. Each model vertex represents a position within the mesh region corresponding to the first model part and is the smallest unit constituting the first model part. The distribution of model vertices determines the shape of the first model part, and the distribution of model vertices within the mesh region corresponding to the first model part is set according to the structural requirements of the first model part during the 3D model modeling process. Similarly, when a 3D model is implemented using a point cloud, a binding relationship is established between the first skeleton and the 3D coordinate points in the point cloud. These 3D coordinate points are sampling points in the set of sampling points corresponding to the first model part within the point cloud of the 3D model, possessing coordinates (x, y, z) in 3D space. The distribution of 3D coordinate points determines the shape of the first model part, and the distribution of 3D coordinate points within the point cloud region corresponding to the first model part is set according to the structural requirements of the first model part during the 3D model modeling process.
[0201] To illustrate, the process of modifying the range and intensity of the influence of the first bone on the first model is called skinning. The skinning process of the first bone is implemented by binding the model vertices in the first model part to the first bone to obtain bone binding data.
[0202] In some embodiments, when skinning a first skeleton using a first model portion of a 3D model, skinning weights are assigned to the model vertices of the first model portion. Illustratively, weight data corresponding to the model vertices in the first model portion is obtained; this weight data expresses the degree of motion correlation between the model vertices and the first skeleton. Using this weight data, the model vertices in the first model portion are weighted and bound to the first skeleton to obtain skeleton binding data. That is, by combining the weight data, the motion of the first skeleton is transferred to the model vertices, allowing different positions of the first model portion to exhibit different elastic deformations, more closely resembling the changes in flexible body tissue in the real physical world, thereby improving the generated animation effect.
[0203] Optionally, the aforementioned weight data can be manually set specified values; or, the aforementioned weight data can be dynamically determined based on the prop attachment status of the first model section.
[0204] In one example, as shown in FIG6, a schematic diagram of a first model portion 600 provided in an exemplary embodiment of the present application is shown. The first model portion 600 is the thigh model portion of a first object. In order to obtain a smooth leg contour of the first object during the animation display, it is necessary to give a smooth weight decay during the binding process of the first bone and the first model portion 600. That is, the highest weight value is set at the fullest position 601 in the first model portion 600, and the weights are gradually decayed in the directions 602 and 603.
[0205] In some embodiments, the obtained skeleton binding data includes: skeleton hierarchy data, used to determine the parent-child connection relationship between the first bone and model bones in the model skeleton of the 3D model; bone position data of the first bone, including the positions of the bone start point and bone end point of the first bone; bone orientation data of the first bone; weight data, used to determine the binding weight between the model vertex and the first bone; animation data of the skeleton animation of the first bone, used to determine the animation information of the first bone (e.g., keyframe position, rotation, scaling and other attribute information); binding pose data of the first bone, used to determine the initial pose and transition pose of the 3D model, wherein the transition pose is a specific pose during the transformation of the 3D model from the initial pose to the target pose; skeleton constraint data of the first bone, used to determine the constraint relationship between the first bone and model bones (e.g., rotation limit value, inverse dynamics constraint, forward dynamics constraint, etc.); and basic attribute data, used to determine the basic attributes of the first bone such as its identifier, name, size, and color.
[0206] That is, by creating or selecting virtual bones to carry shape change triggers, the generated bone binding data can be reused for other similar virtual objects, thereby reducing the amount of computation during animation generation.
[0207] Step 450: Obtain model motion data.
[0208] Among them, the model motion data is used to control the motion of at least one part of the model, representing the first object performing a first action.
[0209] In some embodiments, the model motion data includes at least one of the following: motion animation corresponding to the first motion, motion control interaction data, motion parameters, and second skeletal motion data.
[0210] Step 460: Obtain parameter assignment data for at least one deformation control parameter corresponding to the model motion data.
[0211] Among them, at least one deformation control parameter is used to express the motion characteristics or body tissue characteristics of flexible body tissue when performing the first action.
[0212] In this embodiment, morphological change data is generated by using deformation control parameters for the morphological change trigger.
[0213] Optionally, taking the shape change trigger as an example of a spring controller, the above deformation control parameters include at least one of the following parameters:
[0214] 1. Mass parameter; 2. Drag parameter; 3. Tension parameter; 4. Damping parameter; 5. Axial ratio parameter.
[0215] In some embodiments, the parameter assignment data for at least one deformation control parameter may be data obtained through manual testing.
[0216] In one example, taking the method implemented using 3ds Max as an example, after creating a spring controller for the first skeleton, 3ds Max provides the user with a parameter setting interface for the spring controller. The user inputs the parameter assignment data for the deformation control parameters corresponding to the spring controller in the parameter setting interface. As shown in Figure 7, it is a schematic diagram of the parameter setting interface 700 for the deformation control parameters of the spring controller provided in an exemplary embodiment of this application. The parameter setting interface 700 includes a setting control 701 for mass parameters, a setting control 702 for resistance parameters, a setting control 703 for tension parameters, a setting control 704 for damping parameters, and a setting control 705 for axial ratio parameters.
[0217] In some embodiments, when setting the parameter assignment data for the deformation control parameters of the shape change trigger, the deformation control parameters are set based on data frames in the motion animation. Illustratively, the model motion data includes motion animation; at least one data frame in the motion animation is acquired, wherein the at least one data frame is used to indicate a timestamp node indicating a change in the motion state of the first motion; parameter assignment data corresponding to each of the at least one data frame is acquired.
[0218] The data frame is used to store at least one type of data, such as motion parameters or motion data, corresponding to the first action in the motion animation.
[0219] In some embodiments, the data frame includes keyframes set when creating the motion animation of the first action. The keyframes define attributes such as the position, rotation, and scaling of the first object in the motion animation. In one example, at least one keyframe corresponding to the motion animation of the first action is obtained as at least one data frame.
[0220] In some embodiments, the data frame includes motion parameters for implementing a first action, including action execution duration, motion path, action type, associated skeletons related to the first action, etc. In one example, the motion parameters corresponding to at least one timestamp node of the first action are obtained as at least one data frame.
[0221] The difference between the keyframes and the motion parameters is that the keyframes represent the state of the 3D model during or at the end of the execution of the first action, while the motion parameters are the factors that determine the execution process and result of the first action.
[0222] Optionally, obtaining the deformation control parameters corresponding to the data frame is achieved by: determining the action intensity of the first action at the i-th timestamp node based on the i-th data frame, and obtaining parameter assignment data that matches the action intensity corresponding to the i-th timestamp node.
[0223] In some embodiments, a parameter mapping table between different motion intensities and deformation control parameters is pre-set, and the parameter assignment data corresponding to the motion intensity of the i-th timestamp node is obtained by obtaining the parameter mapping table.
[0224] In some embodiments, the determination of the action intensity corresponding to the first action at the i-th timestamp node is implemented as follows: Optionally, when the i-th data frame includes a keyframe corresponding to the first action, the acceleration corresponding to the 3D model at the i-th timestamp node is determined based on the (i-1)-th, i-th, and (i+1)-th data frames, and this acceleration is used as the action intensity corresponding to the i-th timestamp node. That is, the position point under the first action at the (i-1)-th timestamp node is determined based on the (i-1)-th data frame, the position point under the first action at the i-th timestamp node is determined based on the i-th data frame, and the position point under the first action at the (i+1)-th timestamp node is determined based on the (i+1)-th data frame. The acceleration corresponding to the 3D model at the i-th timestamp node can be calculated using the above three position points and the time difference between the timestamp nodes. Optionally, when the i-th data frame includes action parameters, the acceleration corresponding to the 3D model at the i-th timestamp node is calculated based on the action execution duration and motion path in the action parameters corresponding to the i-th data frame, and this acceleration is used as the action intensity corresponding to the i-th timestamp node.
[0225] Step 470: Input the parameter assignment data of at least one deformation control parameter into the shape change trigger to obtain the output data of the shape change trigger as the first bone motion data of the first bone.
[0226] The first skeleton motion data is used to indicate the motion of the first skeleton when the first object performs the first action.
[0227] In a schematic way, after establishing a constraint relationship between the shape change trigger and the model skeleton of the 3D model, the action generated by the model skeleton of the 3D model when performing the first action affects the shape change trigger to control the movement of the first bone, thereby driving the shape change of the first model part through the movement of the first bone.
[0228] In some embodiments, the first bone motion data includes at least one of the displacement, rotation, and scaling of the first bone in at least one axis.
[0229] In some embodiments, the motion animation includes at least two data frames. When setting the parameter assignment data of the deformation control parameter of the shape change trigger according to the data frame of the motion animation, the parameter assignment data corresponding to the i-th data frame in the at least two data frames is used as the input of the shape change trigger to obtain the i-th bone motion data of the first bone, where i is a positive integer.
[0230] For example, when the motion animation includes multiple data frames, the multiple data frames are sequentially assigned the i-th parameter value data corresponding to the i-th data frame to the shape change trigger according to the timestamp order of the data frames in the motion animation. The output data of the shape change trigger based on the i-th parameter value data is used as the i-th bone motion data of the first bone at the timestamp corresponding to the i-th data frame. It is worth noting that the implementation method of obtaining bone motion data by the shape change trigger according to the deformation control parameters has been described in the previous embodiment and will not be repeated here.
[0231] In some embodiments, the motion data of the i-th bone corresponding to the first bone is used to generate the i-th data frame of the first bone in the skeletal animation.
[0232] Step 480: Control the first model part according to the first bone motion data to obtain the morphological change data of the first model part.
[0233] Schematic, based on the motion data of the first skeleton, the model vertices in the first model part are controlled to perform vertex movements, thereby obtaining the morphological change data of the first model part. The model vertices in the first model part are used to represent the morphology of flexible body tissue; that is, vertex movements are used to drive the morphological changes of the first model part with the model vertices as motion anchors. The first skeleton is driven by a morphological change trigger to produce elastic deformation. Specifically, under the action of the first action, the morphological change trigger causes the bone termination point corresponding to the deformation movement point in the first skeleton to move. The movement of the bone termination point drives the model vertices in the first model part to produce a movement effect corresponding to the movement of the bone termination point. The model vertices, as motion anchors, drive the edges between the model vertices to undergo morphological changes, thereby causing the polygons formed by the model vertices and edges to undergo morphological changes. The morphological changes of the polygons form the morphological changes of the flexible body tissue represented by the first model part, thus realizing the synchronous movement of the first model part by the first skeleton representing the flexible body tissue.
[0234] The first bone motion data indicates the motion information generated by the first bone under the influence of the first action (including at least one type of motion information such as initial shaking frequency, initial motion speed, initial shaking amplitude, motion direction, and shaking decay speed). The motion information corresponding to the first bone in the first bone motion data is converted into the motion information corresponding to the model vertices in the first model part, so that the model vertices in the first model part generate vertex motion under the influence of the first bone. The vertex motion corresponding to all model vertices in the first model part forms the tissue animation corresponding to the flexible body tissue, thereby showing the morphological change data.
[0235] Optionally, the conversion of the motion information of the first bone indicated by the motion data of the first bone into the motion information of the model vertices can be achieved by: directly using the motion information of the first bone as the motion information corresponding to the model vertices in the first model part; or, weighting the motion information of the first bone according to the weight data used in the skinning process of the first model part and the first bone to obtain the motion information corresponding to the model vertices in the first model part.
[0236] For example, when the deformation motion point of the shape change trigger is bound to the bone termination point of the first bone, and the bone termination point of the first bone generates a first displacement on the x-axis, the first displacement controls the model vertices in the first model part to move on the x-axis, or the first displacement is weighted to obtain a second displacement, and the second displacement controls the model vertices in the first model part to move on the x-axis.
[0237] For example, the first model part includes model vertex A, model vertex B, and model vertex C. The weight data corresponding to model vertex A is 0.8, the weight data corresponding to model vertex B is 0.6, and the weight data corresponding to model vertex C is 0.2. When the bone motion point of the first bone generates a first displacement along the positive x-axis under the control of the shape change trigger, model vertex A generates a displacement along the positive x-axis by a distance of 0.8 times the first displacement based on the weight data; model vertex B generates a displacement along the positive x-axis by a distance of 0.6 times the first displacement based on the weight data; and model vertex C generates a displacement along the positive x-axis by a distance of 0.2 times the first displacement based on the weight data.
[0238] By using the first skeleton bound to the first model part to drive the movement of the model vertices in the first model part, the movement of the model vertices changes the shape of the flexible body tissue displayed by the first model part, improving the accuracy of the effect of the first action on the shape change of the flexible body tissue, and further enhancing the dynamic performance of the 3D model.
[0239] In some embodiments, when setting the deformation control parameters of the shape change trigger according to the data frame of the motion animation, after obtaining the i-th bone motion data of the first bone through the i-th parameter assignment data corresponding to the i-th data frame, the first model part is controlled according to the i-th bone motion data to obtain the inter-frame shape change data corresponding to the i-th data frame. The inter-frame shape change data is used to indicate the shape change of the first model part between the i-th data frame and the (i+1)-th data frame. The shape change data of the first model part is obtained based on the inter-frame shape change data corresponding to at least two data frames respectively.
[0240] At the timestamp node corresponding to the i-th data frame, the i-th bone motion data indicates the motion information generated by the first bone at that timestamp node under the influence of the first action. The motion information corresponding to the first bone in the i-th bone motion data is transformed into the motion information corresponding to the model vertices in the first model part, so that the model vertices in the first model part generate vertex motion under the influence of the first bone. Since the spring can generate continuous motion under the action of an initial force, under the influence of the first action corresponding to the timestamp node corresponding to the i-th data frame, the i-th bone motion data can indicate the motion information between the timestamp node corresponding to the i-th data frame and the timestamp node corresponding to the i+1-th data frame. Thus, the i-th bone motion data can control the model vertices in the first model part to perform continuous vertex motion between the i-th data frame and the i+1-th data frame, thereby obtaining the inter-frame morphological change data of the flexible body tissue under the influence of the i-th data frame.
[0241] After obtaining the inter-frame morphological change data, the inter-frame morphological change data is combined according to the temporal order between the data frames to obtain the morphological change data of the first model part. Optionally, the inter-frame morphological change data corresponding to different data frames can be stored independently, that is, the order of the inter-frame morphological change data when combined to obtain the morphological change data is represented by recording the temporal order between the data frames; alternatively, the inter-frame morphological change data of different data frames are spliced together according to the temporal order between the data frames to obtain the morphological change data.
[0242] That is, the deformation control parameters of the input shape change trigger are determined by the data frame corresponding to the first action provided by the motion animation. Then, the deformation control parameters are used to control the elastic deformation of the flexible body tissue, so that the shape change data of the obtained flexible body tissue is closer to the action influence of the first action, while ensuring the consistency between the action performance of the first action and the shape change performance of the flexible body tissue.
[0243] In summary, to represent the morphological changes of the flexible body tissue in the corresponding 3D model when the first object performs the first action, a first skeleton is bound to the first model part corresponding to the flexible body tissue, and a corresponding morphological change trigger is created for the first skeleton. By configuring deformation control parameters for the morphological change trigger, the first skeleton is driven to move, and the first skeleton drives the first model part to produce morphological changes, thereby showing the dynamic effect of the flexible body tissue under the influence of the first action, thus improving the realism of the dynamic performance of the flexible body tissue.
[0244] In some optional embodiments, props attached to the 3D model can affect the movement of the flexible body tissue of the 3D model. For example, virtual clothing worn by a virtual character can restrict the shaking of virtual muscles. In the embodiments of this application, when establishing the binding relationship between the shape change trigger and the first model part through the first bone, weighted binding is performed so that diverse shape change effects produced by the flexible body tissue under the influence of props can be achieved under the control of a single bone.
[0245] Please refer to Figure 8, which shows a flowchart of a three-dimensional model data processing method provided in an exemplary embodiment of this application. The method is illustrated by an example of it being executed by a computer device, which can be implemented as a terminal and / or a server. The method includes at least one step from steps 410 to 482. Embodiments of this application can be implemented as independent embodiments or in combination with any other embodiments, and are not limited herein.
[0246] Step 410: Obtain a three-dimensional model of the first object. The three-dimensional model includes at least one model part, and the at least one model part includes the first model part corresponding to the flexible body tissue of the first object.
[0247] In this embodiment of the application, the three-dimensional model of the first object includes at least one model portion, wherein the model portion is used to indicate the parts that make up the three-dimensional model of the first object.
[0248] In some embodiments, after obtaining the three-dimensional model of the first object, the shape of a part of the model in the three-dimensional model of the first object is modified, so as to ensure that the volume change of the model part when the three-dimensional model performs the first action conforms to the change effect of flexible body tissue in the physical world.
[0249] Schematic, at least one second model part is determined from at least one model part, wherein the second model part is a model part in the three-dimensional model that participates in performing the first action; a third skeleton is bound to at least one second model part, wherein the third skeleton is used to control the volume change of the second model part when the three-dimensional model performs the first action.
[0250] In some embodiments, the second model portion may be a model portion that participates in the first action, pre-divided according to the model structure during the process of creating the model action data for the first action. For example, when the first action is implemented as a running action, the second model portion includes the chest cavity portion and limb portions of the three-dimensional model.
[0251] In some embodiments, the second model portion may be selected during the generation of morphological change data. Illustratively, during the generation of morphological change data, the terminal displays a 3D model of a first object, receives a user's selection operation on a model portion within the 3D model of the first object, and determines the second model portion based on the selection operation. For example, the user selects the second model portion from the 3D model using a selection tool.
[0252] Optionally, the second model part is the same as the first model part; or, the second model part is a subset of the first model part; or, the first model part is a subset of the second model part.
[0253] In a schematic way, the third skeleton is implemented as an auxiliary skeleton when the three-dimensional model performs the first action. An auxiliary skeleton is a structure used to help shape the form of the first object, focusing on playing a supporting and guiding role in shaping the external form of the three-dimensional model.
[0254] Optionally, the aforementioned third skeleton can be implemented as a series of connected line segments or a mesh, without limitation.
[0255] In some embodiments, the process of modifying the second model part through the third bone includes: creating the third bone by setting the bone parameters of the third bone, the bone parameters including the bone start point, bone end point and bone structure of the third bone; setting the bone position of the third bone in the three-dimensional model according to the volume change required by the second model part during the execution of the first action; and skinning the third bone using the second model part of the three-dimensional model to establish the binding relationship between the third bone and the second model part.
[0256] Step 420: Create the first skeleton.
[0257] In this embodiment of the application, a first skeleton is created for the first model part. The creation process of the first skeleton is implemented by setting the skeleton parameters of the first skeleton to create the first skeleton. The skeleton parameters include the skeleton start point, the skeleton end point and the skeleton structure of the first skeleton.
[0258] Step 430: Construct the morphological change trigger corresponding to the first bone.
[0259] The shape change trigger is used to control the elastic deformation of the first skeleton according to deformation control parameters. In one example, the shape change trigger is implemented as a spring controller, which controls the first skeleton to simulate spring movement. A spring controller is a controller used to simulate spring effects. A spring controller can add secondary dynamic effects to the position of any point or object. In this embodiment, the spring controller is used to control the movement of the first skeleton to drive the first model part to achieve a spring-like effect.
[0260] Step 441: Based on the prop attachment status of the first model part, obtain the weight data corresponding to the model vertices in the first model part.
[0261] The weight data is used to indicate the degree of motion correlation between the model vertex and the first bone when the prop is attached. For example, the weight data can characterize the constraint effect of the prop attachment on the morphological changes of the flexible body tissue.
[0262] Optionally, the aforementioned prop attachment status includes at least one of the following: whether the first model portion is attached to a prop, the type of prop to which the prop is attached, the number of props to which the prop is attached, and the area of the model portion to which the prop is attached.
[0263] Optionally, the virtual props attached to the first model part include virtual items, virtual clothing, virtual accessories, etc.
[0264] In some embodiments, when the first model portion has virtual props attached to it, and the attachment of virtual props to the first model portion results in model sub-parts with different morphological requirements, different weights are assigned to the different model sub-parts. Illustratively, when the prop attachment status of the first model portion indicates that the first model portion includes at least two model sub-parts, the first model portion is divided into at least three model regions, wherein there are prop attachment differences between the at least two model sub-parts, and the at least three model regions include a first region corresponding to each of the at least two model sub-parts, and a second region where adjacent model sub-parts in the at least two model sub-parts have a boundary relationship; a first weight is set for the first region based on the prop attachment status of the model sub-parts; a second weight is set for the second region based on the prop attachment differences between adjacent model sub-parts, wherein the first weight and the second weight are used as weight data to weightedly bind the model vertices in the first model portion to the first skeleton to obtain skeleton binding data.
[0265] Optionally, the division of at least three model regions can be a model region obtained by the animator manually dividing the first model part.
[0266] Optionally, the division of at least three model regions can be obtained through a pre-trained region segmentation model. In some embodiments, the region segmentation model is a machine learning model trained using sample model data labeled with prop attachment information. Illustratively, the sample data includes sample models and sample segmentation results. Prop attachment information and sample models are input into the region segmentation model to be trained, and a predicted segmentation result is obtained. Therefore, based on the difference between the predicted segmentation result and the sample segmentation result, the region segmentation model to be trained is trained, resulting in the aforementioned region segmentation model. The prop attachment situation of the first model portion is analyzed using the region segmentation model, dividing the first model portion into at least three model regions.
[0267] In some embodiments, setting a first weight for a first region based on the prop attachment status of a model sub-part is achieved by: obtaining the prop type of the virtual props attached to the model sub-part, obtaining the first weight corresponding to the prop type, and setting the first weight for the first region. That is, when virtual props of different prop types are attached to a model sub-part, they produce different constraint effects on the model sub-part. For example, when the prop type of the virtual prop is loose clothing, the first weight is a larger value, that is, since loose clothing has less motion constraint on the first model part, it has less impact on the driving effect of the shape change trigger on the first model part; as another example, when the prop type of the virtual prop is tight clothing, the first weight is a smaller value, that is, since tight clothing has greater motion constraint on the first model part, it has a greater impact on the driving effect of the shape change trigger on the first model part. For example, the contraction of leg muscles by virtual stockings means that the shaking effect needs to be reduced when representing leg muscle shaking.
[0268] In some embodiments, setting a second weight for the second region based on the prop attachment difference between adjacent model sub-parts is implemented as follows: obtaining the prop attachment strength difference value between adjacent model sub-parts, and when the prop attachment strength difference value reaches a third threshold, obtaining a specified weight value as the second weight of the second region, wherein the specified weight value is a small value, and in one example, the specified weight value is 0.
[0269] In one example, as shown in FIG9, a schematic diagram of the setting of weight data of the first model part 900 provided in an exemplary embodiment of the present application is shown. The first model part 900 includes a first model sub-part 910 and a second model sub-part 920. Since the second model sub-part 920 is attached with virtual clothing, there is a constraint on the jitter effect of the shape change trigger. For example, a weight A is set for region 911 corresponding to the first model sub-part 910, a weight B is set for region 921 corresponding to the second model sub-part 920, and a weight C is set for the boundary region 922 between the first model sub-part 910 and the second model sub-part 920. Here, weight A can be set to a smooth weight decay from the center outward as shown in Figure 6, weight B can be set to a weight influence that disappears linearly, and weight C can be set to a weight value much lower than weight A. Thus, when the first bone shakes under the influence of the shape change trigger, due to the sudden decrease of weight C compared to weight A, the shaking deformation of the second model sub-part 920 presents a visual effect of being "stuck," thereby reflecting the contrast of the contour of the flexible body tissue during movement under different prop attachment effects and emphasizing the curve of the "expansion" produced by the stuck flesh.
[0270] That is, by setting special weights for the boundary areas where there are differences in prop attachment between the sub-parts of the model, the contrast of the contours of flexible body tissues during movement under different prop attachment effects can be reflected, further improving the realism of the dynamic performance.
[0271] Step 442: Using the weight data, the model vertices in the first model part are weighted and bound to the first skeleton to obtain the skeleton binding data.
[0272] In illustrative terms, the process of modifying the range and intensity of the influence of the first bone on the first model part is called skinning. In this embodiment, the weight data is used as skinning weights to skin the first bone using the first model part, thereby establishing the binding relationship between each model vertex in the first model part and the first bone, and obtaining bone binding data.
[0273] Indicatively, the weight data includes the weight values corresponding to the model vertices in the first model part. These weight values represent the degree of influence of the first skeleton on the model vertices. The weighted binding process between the model vertices and the first skeleton is implemented as follows: obtain the i-th weight value corresponding to the i-th model vertex from the weight data, establish the binding mapping relationship between the i-th model vertex, the first skeleton, and the i-th weight value, and store and record the binding mapping relationships corresponding to the model vertices in the first model part, thereby completing the weighted binding between the model vertices and the first skeleton.
[0274] Step 450: Obtain model motion data.
[0275] Among them, the model motion data is used to control the motion of at least one part of the model, representing the first object performing a first action.
[0276] In some embodiments, the model motion data includes at least one of the following: motion animation corresponding to the first motion, motion control interaction data, motion parameters, and second skeletal motion data.
[0277] Step 460: Obtain parameter assignment data for at least one deformation control parameter corresponding to the model motion data.
[0278] Among them, at least one deformation control parameter is used to express the motion characteristics or body tissue characteristics of flexible body tissue when performing the first action.
[0279] In this embodiment, morphological change data is generated by using deformation control parameters for the morphological change trigger.
[0280] Optionally, taking the shape change trigger as an example of a spring controller, the above deformation control parameters include at least one of the following parameters:
[0281] 1. Mass parameters; 2. Resistance parameters; 3. Tension parameters; 4. Damping parameters; 5. Axial ratio parameters, including X-axis ratio parameters, Y-axis ratio parameters, and Z-axis ratio parameters.
[0282] In some embodiments, the parameter assignment data for at least one deformation control parameter may be parameter data obtained through manual testing.
[0283] In some embodiments, when setting the parameter assignment data for the deformation control parameters of the shape change trigger, the deformation control parameters are assigned based on data frames in the motion animation. Illustratively, the model motion data includes motion animation; at least one data frame in the motion animation is obtained, wherein the at least one data frame is used to indicate a timestamp node indicating a change in the motion state of the first motion; and parameter assignment data for the deformation control parameters corresponding to each of the at least one data frame is obtained.
[0284] That is, when generating parameter assignment data, the data frames in the motion animation are combined so that the morphological changes shown by the generated parameter assignment data can match the actions shown in the motion animation, thereby improving the realism of the dynamic performance of flexible body tissues under the actions shown in the motion animation.
[0285] Step 470: Input the parameter assignment data of at least one deformation control parameter into the shape change trigger to obtain the output data of the shape change trigger as the first bone motion data of the first bone.
[0286] The first skeleton motion data is used to indicate the motion of the first skeleton when the first object performs the first action.
[0287] In a schematic way, after establishing a constraint relationship between the shape change trigger and the model skeleton of the 3D model, the action generated by the model skeleton of the 3D model when performing the first action affects the shape change trigger to control the movement of the first bone, thereby driving the shape change of the first model part through the movement of the first bone.
[0288] In some embodiments, the first bone motion data includes at least one of the displacement, rotation, and scaling of the first bone in at least one axis.
[0289] In some embodiments, when setting the deformation control parameters of the shape change trigger according to the data frames of the motion animation, the parameter assignment data corresponding to the i-th data frame in at least one data frame is used as the input of the shape change trigger to obtain the i-th bone motion data of the first bone, where i is a positive integer.
[0290] In some embodiments, the motion data of the i-th bone corresponding to the first bone is used to generate the i-th data frame of the first bone in the skeletal animation.
[0291] Step 481: Weight the first skeleton motion data using weight data to obtain the vertex motion data corresponding to the model vertex.
[0292] In this embodiment, when the first model part is bound to the first skeleton, the model vertices are assigned weight data. When the shape of the first model part is driven to change by the first skeleton, the weight value corresponding to each model vertex in the first model part is determined according to the weight data. The motion data of the first skeleton is weighted according to the weight value to obtain the vertex motion data corresponding to the model vertex.
[0293] In some embodiments, vertex motion data includes at least one of the displacement, rotation, and scaling of the model vertex in at least one axis.
[0294] Step 482: Control the vertex of the model to perform vertex motion based on vertex motion data to obtain the morphological change data of the first model part.
[0295] In this model, the model vertices in the first model section are used to represent the shape of the flexible body tissue. Specifically, vertex motion is used to drive shape changes in the first model section using the model vertices as motion anchors. Shape change data is used to represent the shape changes of the flexible body tissue during the first object's execution of the first action. In other words, by combining weight data, the first bone motion data of the first skeleton is converted into vertex motion data of the model vertices. This vertex motion data is then used to control the vertex motion of the model vertices. This ensures different performance effects for different parts of the first model section when showing shape changes, and also makes the vertex motion of the model vertices smoother and more natural.
[0296] In some embodiments, when setting the deformation control parameters of the shape change trigger according to the data frame of the motion animation, after obtaining the motion data of the i-th bone of the first bone through the i-th deformation control parameters corresponding to the i-th data frame, the motion data of the i-th vertex is obtained by weighting the motion data of the i-th bone through weight data. The corresponding model vertex is controlled to perform vertex motion according to the motion data of the i-th vertex to obtain the inter-frame shape change data corresponding to the i-th data frame. The inter-frame shape change data is used to indicate the shape change of the first model part between the i-th data frame and the (i+1)-th data frame. The shape change data of the first model part is obtained based on the inter-frame shape change data corresponding to at least one data frame.
[0297] In summary, to represent the morphological changes of the flexible body tissue in the corresponding 3D model when the first object performs the first action, a first skeleton is bound to the first model part corresponding to the flexible body tissue, and a corresponding morphological change trigger is created for the first skeleton. By configuring deformation control parameters for the morphological change trigger, the first skeleton is driven to move, and the first skeleton drives the first model part to produce morphological changes, thereby showing the dynamic effect of the flexible body tissue under the influence of the first action, thus improving the realism of the dynamic performance of the flexible body tissue.
[0298] Furthermore, when binding the first skeleton and the first model part, the weight data for binding between the two is dynamically set according to the prop attachment status of the first model part. In this way, the weight data represents the constraint effect of prop attachment status on the shape change of flexible body tissue. At the same time, since different weights can be configured for different model vertices of the first model part, the number of first skeletons bound to the first model part can be reduced, thus reducing the number of first skeletons and consequently reducing the amount of shape change data obtained.
[0299] Optionally, the application scenarios of this application embodiment may include, but are not limited to: character modeling scenarios, scene modeling scenarios, special effects modeling scenarios, etc. in the fields of games and animation; industrial product modeling scenarios, etc. in the manufacturing field; biological modeling scenarios, medical device design modeling scenarios, etc. in the medical field; virtual classroom modeling scenarios, virtual laboratory modeling scenarios, etc. in the education field.
[0300] In one example, taking a virtual character as the first object, the first model part as the buttocks model and thigh model of the virtual character, and a spring controller as the shape change trigger, the following is an illustrative explanation of the shaking effect of virtual muscles during movement achieved through the spring controller. Please refer to Figure 10, which shows a flowchart of a three-dimensional model data processing method provided in an exemplary embodiment of this application. The method is illustrated by example, with the method being executed by a computer device, which can be implemented as a terminal and / or a server. The process includes at least one step from steps 1001 to 1006. Embodiments of this application can be implemented as independent embodiments or in combination with any other embodiments, and are not limited herein.
[0301] Step 1001: Use auxiliary skeletons to bind the 3D model of the virtual character, and add shaping functions for the buttocks and thighs model parts through auxiliary skeletons.
[0302] Schematic illustration: A three-dimensional model of a virtual character is obtained, the three-dimensional model including a hip model portion and a thigh model portion of the virtual character. For example, as shown in FIG11, which illustrates a schematic diagram of a three-dimensional model 1100 provided in an exemplary embodiment of this application, wherein the three-dimensional model 1100 includes a hip model portion 1110 and a thigh model portion 1120.
[0303] Among them, auxiliary skeletons are structures used to help shape the form of the primary object, focusing on playing a supporting and guiding role in the external shape shaping of the three-dimensional model.
[0304] To illustrate, for the obtained 3D model of the virtual character, the shape of the hip model and the area near the root of the thigh in the thigh model is first corrected using auxiliary skeletons, so that when the legs are raised in all directions, the volume change of the hip model and the thigh model is consistent with the effect of muscles in the real world.
[0305] Alternatively, the auxiliary skeleton can be implemented as a series of connected line segments or a grid, without limitation.
[0306] In some embodiments, the auxiliary skeleton is bound to the model skeleton of the three-dimensional model.
[0307] Step 1002: Add muscle skeletons to the muscle areas of the buttock model and thigh model, and add spring controllers to the muscle skeletons.
[0308] Then, add musculoskeletal structures to the revised hip and thigh models, and create spring controllers for the musculoskeletal structures.
[0309] Optionally, corresponding muscle bones can be added to the buttock model and the thigh model respectively. In some embodiments, to minimize the number of muscle bones, one muscle bone is added to the buttock model and one muscle bone is added to the thigh model. It is worth noting that multiple muscle bones can be added to a single model part; this is only an illustrative example of one muscle bone per model part, and the specific number is not limited.
[0310] The spring controller is used to control the musculoskeletal system to simulate spring movement. It's a controller designed to mimic the effect of a spring. The spring controller can add secondary dynamic effects to the position of any point or object.
[0311] Indicatively, the spring controller is used to control musculoskeletal movement to drive the hip and thigh model parts to achieve the spring-like effect.
[0312] Step 1003: Adjust the skin of the musculoskeletal structure and test the deformation effect of the buttock and thigh model parts.
[0313] In some embodiments, considering that when the thigh muscles tremble, the spring simulation only produces displacement animation, it is necessary to characterize the contour changes required during the animation and the effect of virtual clothing constricting the flesh through weights, so that the desired deformation can be obtained by translating the bones.
[0314] For models where there are no changes in the attachment of virtual clothing, in order to achieve a smooth outline for virtual characters in games or animations, it is necessary to apply a smooth weight decay to the muscles and bones. The smooth weight decay is shown in Figure 6, and will not be elaborated here.
[0315] For models where virtual clothing has varying attachments, it is necessary to consider the contrast in the outlines of virtual clothing of different materials during movement, emphasizing the curves that create a sense of "expansion" when the flesh is constricted, as a requirement for the outline when muscles tremble. For example, if a virtual character is wearing tight pants or armor that is tightly bound to the thighs, the area covered by the tight pants or armor and the area not covered need to show a "constricting" effect.
[0316] This illustration demonstrates how varying weights are added to the model based on the attachment of different virtual garments. For example, taking a thigh model with tights attached, a dividing line is first drawn at the junction of the buttock / thigh muscle area and the tights, separating the model into two regions (region A and region B). Region A is the buttock model area, and region B is the thigh model area including the tights. Since region A corresponds to muscle and fat, its overall weight is greater than that of region B, and the weight of region A gradually decreases from its maximum value upwards. Region B is the restricted area of the tights, so the weight effect disappears linearly, and the weight at the junction of region A and region B (the junction of the tights) drops sharply, causing the deformation of region B to appear "stuck" during translation of the musculoskeletal structure.
[0317] Indicatively, through animation tests in the horizontal and vertical directions, it is determined whether the set weights meet business requirements.
[0318] Step 1004: Import the character animation of the virtual character.
[0319] The character animation refers to the animation data corresponding to the virtual character performing its first action. Optionally, the animation data includes image data (e.g., image frames, resolution, color depth, etc.), time data (e.g., animation duration, timestamps corresponding to each action node of the first action, timeline, etc.), and motion data (e.g., keyframes, motion curves, etc., where keyframes are used to define the virtual character's position, rotation, scaling, and other attributes in the character animation, and the computer device will automatically interpolate and generate intermediate frames based on the keyframes to create smooth motion of the 3D model).
[0320] Step 1005: Adjust the deformation control parameters of the spring controller according to the character animation, and add keyframe animations corresponding to the muscles and bones.
[0321] This example illustrates adjusting the deformation control parameters of the spring controller during character animation and creating keyframes for it. Specifically, the amplitude of the jitter is determined by the mass value, the speed of the jitter rebound is adjusted by the drag value, and the frequency of the jitter is adjusted by the tension value (more relaxed or closer to a spring). Finally, the amplitude of the muscle jitter in each axis is adjusted using the X Effect, Y Effect, and Z Effect values.
[0322] Step 1006: Export the skinning data and animation files of the virtual character.
[0323] The skinning data includes skeletal data of the musculoskeletal system, as well as data on the binding relationships between the musculoskeletal system and the hip and thigh models; the animation files include skeletal animations corresponding to the musculoskeletal system and character animations corresponding to the virtual character.
[0324] In some embodiments, after exporting the skinning data and animation files of the virtual character, the skinning data and animation files of the virtual character can be imported into other motion graphics applications (e.g., UE engine). The other motion graphics applications can then perform real-time calculations based on the skinning data and animation files of the virtual character to obtain the animation effect of the virtual character performing the first action. Alternatively, after the skinning data and animation files of the virtual character are imported into other motion graphics applications, the animation production functions provided by the other motion graphics applications can be used to further produce animations based on the skinning data and animation files of the virtual character. For example, skeletal chains can be added to the chain-like structures such as virtual hair, virtual clothing hem, and virtual ribbons of the 3D model to create corresponding skeletal animations.
[0325] In one example, taking a game application implemented as a motion graphics application with a 3D animation engine, the game application renders a 3D model of the virtual character based on the obtained skinning data of the virtual character. This 3D model corresponds to a model skeleton, which includes musculoskeletal structures bound to spring controllers. This model skeleton cannot be directly observed by the player. When the virtual character needs to perform a first action (e.g., receiving a control operation from the player), the 3D animation engine drives the movement of the bones in the model skeleton used to perform the first action through skeletal animation data in the animation file. The binding relationship between the bones, represented by the virtual character's skinning data, and the vertices of the model in the 3D model achieves the motion effect of the 3D model performing the first action driven by the aforementioned skeletal movement. The aforementioned skeletal movement, while driving the model vertices in the 3D model to perform actions, also causes the musculoskeletal system to generate simulated spring movements. The movement of the musculoskeletal system causes the model vertices in the connected hip and / or thigh model parts to produce a shaking effect. The 3D animation engine renders the motion effect of the first action and the shaking effect of the model parts to obtain the motion execution animation of the virtual character in the process of performing the first action. The motion execution animation is displayed on the terminal's screen. The motion execution animation shows the process of the virtual character performing the first action, as well as the shaking visual effect produced by the virtual character's hip and / or thigh model parts during the execution of the first action.
[0326] It should be noted that this application may display prompt interfaces, pop-ups, or output voice prompts before and during the collection of user data. These prompt interfaces, pop-ups, or voice prompts are used to inform the user that their data is being collected. This ensures that the application only begins the steps for collecting user data after receiving confirmation from the user regarding the prompt interface or pop-up; otherwise (i.e., without user confirmation), the steps for collecting user data end, meaning no user data is collected. In other words, all user data collected in this application is collected with the user's consent and authorization, and the collection, use, and processing of related user data must comply with the relevant laws, regulations, and standards of the relevant countries and regions.
[0327] Please refer to Figure 12, which shows a structural block diagram of a three-dimensional model data processing device provided in an exemplary embodiment of this application. The device includes the following modules:
[0328] The first acquisition module 1210 is used to acquire a three-dimensional model of a first object, the three-dimensional model including at least one model part, the at least one model part including a first model part corresponding to the flexible body tissue of the first object;
[0329] Module 1220 is invoked to invoke the shape change trigger, which is used to control the shape change of the first model part through deformation control parameters.
[0330] The second acquisition module 1230 is used to acquire model action data, which is used to control the movement of at least one model part so that the first object performs a first action.
[0331] The generation module 1240 is used to assign values to the deformation control parameters through the shape change trigger based on the model action data, and correspondingly control the first model part to undergo the shape change during the execution of the first action to obtain shape change data.
[0332] In some optional embodiments, as shown in FIG13, the generation module 1240 includes:
[0333] The first acquisition unit 1241 is used to acquire parameter assignment data of deformation control parameters corresponding to the model action data. The deformation control parameters are used to control the deformation effect of the first bone under the influence of the first action, so as to drive the first model part bound to the first bone to generate a shaking corresponding to the deformation effect.
[0334] The generation unit 1242 is used to input the parameter assignment data into the shape change trigger and obtain output data as the first bone motion data of the first bone. The first bone motion data is used to indicate the motion of the first bone when the first object performs the first action.
[0335] The control unit 1243 is used to control the first model part according to the first skeletal motion data to obtain the morphological change data.
[0336] In some optional embodiments, the control unit 1243 is further configured to control the model vertices in the first model part to perform vertex movements based on the first skeletal motion data, thereby obtaining the morphological change data. The vertex movements are used to drive the first model part to undergo morphological changes with the model vertices as motion anchor points.
[0337] In some optional embodiments, the model motion data includes motion animation;
[0338] The first acquisition unit 1241 is further configured to acquire data frames in the motion animation, wherein the data frames are used to indicate timestamp nodes indicating changes in the motion state of the first motion;
[0339] The first acquisition unit 1241 is further configured to acquire the parameter assignment data corresponding to the data frame.
[0340] In some alternative embodiments, the motion animation includes at least two data frames;
[0341] The generation unit 1242 is further configured to use the i-th parameter assignment data corresponding to the i-th data frame in the at least two data frames as the input of the morphological change trigger to obtain the i-th bone motion data of the first bone, where i is a positive integer;
[0342] The control unit 1243 is further configured to control the first model part according to the i-th skeletal motion data to obtain the inter-frame morphological change data corresponding to the i-th data frame, wherein the inter-frame morphological change data is used to indicate the morphological change of the first model part between the i-th data frame and the i+1-th data frame.
[0343] The generation unit 1242 is further configured to obtain the morphological change data based on the inter-frame morphological change data corresponding to the at least two data frames respectively.
[0344] In some alternative embodiments, when the shape change trigger is implemented as a spring controller, the deformation control parameters include at least one of the following parameters:
[0345] The parameters include: a mass parameter indicating the amplitude of jitter of the first bone under the control of the spring controller; a resistance parameter indicating the attenuation amplitude of the movement of the first bone under the control of the spring controller; a tension parameter indicating the stiffness of the first bone under the control of the spring controller; a damping parameter indicating the attenuation rate of the movement of the first bone under the control of the spring controller; and an axial ratio parameter indicating the weight of the jitter amplitude of the first bone in at least one axial direction.
[0346] In some optional embodiments, the calling module 1220 includes:
[0347] A creation unit 1221 is used to create a first bone; or, a second bone in the model skeleton of the three-dimensional model is used as the first bone, wherein the model skeleton is the skeleton data configured in the model making process of the three-dimensional model, and the second bone is the bone in the model skeleton that corresponds to the first model part;
[0348] Construction unit 1222 is used to construct the shape change trigger corresponding to the first bone, and the shape change trigger is used to control the first bone to generate deformation according to the deformation control parameters;
[0349] Binding unit 1223 is used to bind the first bone to the first model part to obtain the bone binding data corresponding to the first model part.
[0350] In some optional embodiments, the creation unit 1221 is further configured to obtain the bone parameters of the first bone, the bone parameters including the bone start point and the bone end point of the first bone, wherein the bone start point and the bone end point are points determined based on the flexible deformation direction and flexible deformation range of the flexible body tissue.
[0351] The creation unit 1221 is further configured to create the first bone based on the bone parameters of the first bone.
[0352] In some optional embodiments, the construction unit 1222 is further configured to obtain a first bone point and a second bone point of the first bone, wherein the first bone point and the second bone point are different positions in the first bone;
[0353] The construction unit 1222 is further configured to construct the shape change trigger by using the first bone point as the deformation fixation point and the second bone point as the deformation movement point. The deformation fixation point is the position where the first bone remains relatively stationary under the control of the shape change trigger, and the deformation movement point is the position where the first bone is displaced under the control of the shape change trigger.
[0354] In some alternative embodiments, the first object includes a person object;
[0355] In the case where the flexible body tissue includes leg tissue, the creation direction of the first bone corresponds to the extension direction of the leg muscles, wherein the distance between the first bone point and the buttock tissue of the human figure is less than the distance between the second bone point and the buttock tissue;
[0356] In the case where the flexible body tissue includes buttock tissue, the buttock tissue includes left and right buttock tissues adjacent to each other at a first adjacency point. The creation direction of the first bone corresponding to the left buttock tissue corresponds to the direction of the line connecting the first adjacency point and the second adjacency point. The second adjacency point is the adjacency point between the left buttock tissue and the leg tissue. The distance between the first bone point and the first adjacency point is less than the distance between the second bone point and the first adjacency point.
[0357] In some alternative embodiments, the first object includes an animal object;
[0358] In the case where the flexible body tissue includes cheek tissue, the creation direction of the first bone corresponds to the outward convex direction of the cheek tissue, wherein the outward convex distance of the first bone point is less than the outward convex distance of the second bone point;
[0359] In the case where the flexible body tissue includes abdominal tissue, the creation direction of the first bone corresponds to the outward convex direction of the abdominal tissue, wherein the outward convex distance of the first bone point is less than the outward convex distance of the second bone point.
[0360] In the case where the flexible body tissue includes tentacled tissue, the tentacled tissue grows at a first external surface location of the animal object, the creation direction of the first bone corresponds to the growth direction of the tentacled tissue, wherein the distance between the first bone point and the first external surface location is less than the distance between the first bone point and the first external surface location.
[0361] In some optional embodiments, the calling module 1220 further includes:
[0362] The second acquisition unit 1224 is used to acquire the weight data corresponding to the model vertices in the first model part, and the weight data is used to express the degree of motion correlation between the model vertices and the first bone.
[0363] The binding unit 1223 is further configured to use the weight data to weightedly bind the model vertices in the first model part to the first bone to obtain the bone binding data.
[0364] In some optional embodiments, the second acquisition unit 1224 is further configured to acquire the weight data corresponding to the model vertices in the first model part based on the prop attachment status of the first model part, wherein the weight data is used to indicate the degree of motion association between the model vertices and the first skeleton when the props are attached.
[0365] In some optional embodiments, the second acquisition unit 1224 is further configured to divide the first model part into at least three model regions when the prop attachment status of the first model part indicates that the first model part includes at least two model sub-parts, wherein there are prop attachment differences between the at least two model sub-parts, and the at least three model regions include a first region corresponding to each of the at least two model sub-parts, and a second region in which there is a boundary relationship between adjacent model sub-parts in the at least two model sub-parts;
[0366] The second acquisition unit 1224 is further configured to set a first weight for the first region based on the prop attachment status of the model sub-parts;
[0367] The second acquisition unit 1224 is further configured to set a second weight for the second region based on the prop attachment differences between the adjacent model sub-parts;
[0368] The first weight and the second weight are used as the weight data.
[0369] In some optional embodiments, the generation unit 1242 is further configured to weight the first skeleton motion data using the weight data to obtain vertex motion data corresponding to the model vertex;
[0370] The control unit 1243 is further configured to control the model vertices to perform vertex movements based on the vertex motion data, thereby obtaining morphological change data of the first model portion, wherein the model vertices in the first model portion are used to represent the morphology of the flexible body tissue.
[0371] In some optional embodiments, the first acquisition module 1210 is further configured to acquire a second model portion from the at least one model portion, wherein the second model portion is the model portion in the three-dimensional model that participates in performing the first action;
[0372] The calling module 1220 is also used to bind a third skeleton to the second model part, the third skeleton being used to control the volume change of the second model part when the three-dimensional model performs the first action.
[0373] It should be noted that the three-dimensional model data processing device provided in the above embodiments is only an example of the division of the above functional modules. In practical applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. In addition, the three-dimensional model data processing device and the three-dimensional model data processing method embodiments provided in the above embodiments belong to the same concept, and the specific implementation process can be found in the method embodiments, which will not be repeated here.
[0374] Figure 14 shows a structural block diagram of a terminal 1400 provided in an exemplary embodiment of this application. The terminal 1400 may be: an in-vehicle terminal, an XR device, a smartphone, a tablet computer, an MP3 player, an MP4 player, a laptop computer, or a desktop computer. The terminal 1400 may also be referred to as user equipment, a portable terminal, a laptop terminal, a desktop terminal, or other names.
[0375] Typically, terminal 1400 includes a processor 1401 and a memory 1402.
[0376] Processor 1401 may include one or more processing cores, such as a quad-core processor, an octa-core processor, etc. In some embodiments, processor 1401 may integrate a graphics processing unit (GPU), which is responsible for rendering and drawing the content that the display screen needs to show. In some embodiments, processor 1401 may also include an artificial intelligence (AI) processor, which is used to handle computational operations related to machine learning.
[0377] The memory 1402 may include one or more computer-readable storage media, which may be non-transitory. In some embodiments, the non-transitory computer-readable storage media in the memory 1402 are used to store at least one instruction, which is executed by the processor 1401 to implement the three-dimensional model data processing method provided in the method embodiments of this application.
[0378] Indicatively, terminal 1400 also includes other components 1403. Those skilled in the art will understand that the structure shown in FIG14 does not constitute a limitation on terminal 1400, and may include more or fewer components than shown, or combine certain components, or use different component arrangements.
[0379] Those skilled in the art will understand that all or part of the steps in the various methods of the above embodiments can be implemented by a program instructing related hardware. This program can be stored in a computer-readable storage medium, which may be a computer-readable storage medium included in the memory described in the above embodiments; or it may be a standalone computer-readable storage medium not assembled into a terminal. The computer-readable storage medium stores at least one instruction, at least one program segment, a code set, or an instruction set. The at least one instruction, the at least one program segment, the code set, or the instruction set is loaded and executed by the processor to implement any of the three-dimensional model data processing methods described in the above embodiments.
Claims
A method for processing three-dimensional model data, the method being executed by a computer device, the method comprising: A three-dimensional model of a first object is obtained, the three-dimensional model including at least one model part, the at least one model part including a first model part corresponding to the flexible body tissue of the first object; The shape change trigger is invoked, and the shape change trigger is used to control the shape change of the first model part through deformation control parameters. Acquire model motion data, which is used to control the movement of at least one model part so that the first object performs a first action; Based on the model action data, the deformation control parameters are assigned values through the shape change trigger, and the shape change of the first model part is controlled accordingly to undergo the shape change during the execution of the first action, thereby obtaining shape change data. According to the method of claim 1, wherein, Based on the model action data, the deformation control parameters are assigned values through the shape change trigger, and the shape change of the first model part is controlled accordingly to undergo the shape change during the execution of the first action, thereby obtaining shape change data, including: Obtain parameter assignment data for deformation control parameters corresponding to the model action data. The deformation control parameters are used to control the deformation effect of the first bone under the influence of the first action, so as to drive the first model part bound to the first bone to produce a shaking corresponding to the deformation effect. The parameter assignment data is input into the shape change trigger to obtain the output data as the first bone motion data of the first bone. The first bone motion data is used to indicate the motion of the first bone when the first object performs the first action. The first model part is controlled based on the first skeletal motion data to obtain the morphological change data. The method according to claim 1 or 2, wherein, The step of controlling the first model based on the first skeletal motion data to obtain the morphological change data includes: Based on the first skeletal motion data, the model vertices in the first model part are controlled to perform vertex motion to obtain the morphological change data; The vertex motion is used to drive the first model part to undergo shape changes with the model vertex as the motion anchor point. The method according to any one of claims 1 to 3, wherein, The model motion data includes motion animation; The step of acquiring parameter assignment data for deformation control parameters corresponding to the model motion data includes: Obtain data frames from the motion animation, where the data frames are used to indicate timestamp nodes indicating changes in the motion state of the first motion; Obtain the parameter assignment data corresponding to the data frame. The method according to any one of claims 1 to 4, wherein, The motion animation includes at least two data frames; The step of inputting the parameter assignment data into the shape change trigger to obtain output data as the first bone motion data of the first bone includes: The i-th parameter assignment data corresponding to the i-th data frame in the at least two data frames is used as the input of the morphological change trigger to obtain the i-th bone motion data of the first bone, where i is a positive integer; The step of controlling the first model based on the first skeletal motion data to obtain the morphological change data includes: The first model part is controlled according to the i-th skeletal motion data to obtain the inter-frame morphological change data corresponding to the i-th data frame. The inter-frame morphological change data is used to indicate the morphological change of the first model part between the i-th data frame and the (i+1)-th data frame. The morphological change data is obtained based on the inter-frame morphological change data corresponding to the at least two data frames respectively. The method according to any one of claims 1 to 5, wherein, When the shape change trigger is implemented as a spring controller, the deformation control parameters include at least one of the following parameters: A mass parameter, which indicates the amplitude of the vibration of the first bone under the control of the spring controller; The resistance parameter indicates the degree of attenuation of the movement of the first bone under the control of the spring controller. Tension parameter, which indicates the stiffness of the first bone under the control of the spring controller when it deforms; Damping parameters, which are used to indicate the rate of decay of the movement of the first bone under the control of the spring controller; Axial magnification parameter, which is used to indicate the weight of the amplitude of the first bone jitter in at least one axis. The method according to any one of claims 1 to 6, wherein, The call format change trigger includes: Create a first bone; or, use the second bone in the model skeleton of the three-dimensional model as the first bone, wherein the model skeleton is the skeleton data configured in the model making process of the three-dimensional model, and the second bone is the bone in the model skeleton that corresponds to the first model part; Construct the shape change trigger corresponding to the first bone, and the shape change trigger is used to control the first bone to produce deformation according to the deformation control parameters; The method further includes: Bind the first bone to the first model part to obtain the bone binding data corresponding to the first model part. The method according to any one of claims 1 to 7, wherein, The creation of the first skeleton includes: Obtain the bone parameters of the first bone, the bone parameters including the bone start point and the bone end point of the first bone, wherein the bone start point and the bone end point are points determined based on the flexible deformation direction and flexible deformation range of the flexible body tissue. The first bone is created based on the bone parameters of the first bone. The method according to any one of claims 1 to 8, wherein, The construction of the morphological change trigger corresponding to the first bone includes: Obtain the first bone point and the second bone point of the first bone, wherein the first bone point and the second bone point are points in the first bone determined based on the flexible deformation range; Using the first bone point as the deformation fixation point and the second bone point as the deformation movement point, the shape change trigger is constructed. The deformation fixation point is the position where the first bone remains relatively stationary under the control of the shape change trigger, and the deformation movement point is the position where the first bone undergoes displacement under the control of the shape change trigger. The method according to any one of claims 1 to 9, wherein, The first object includes a character object; In the case where the flexible body tissue includes leg tissue, the creation direction of the first bone corresponds to the extension direction of the leg muscles, wherein the distance between the first bone point and the buttock tissue of the human figure is less than the distance between the second bone point and the buttock tissue; In the case where the flexible body tissue includes buttock tissue, the buttock tissue includes left and right buttock tissues adjacent to each other at a first adjacency point. The creation direction of the first bone corresponding to the left buttock tissue corresponds to the direction of the line connecting the first adjacency point and the second adjacency point. The second adjacency point is the adjacency point between the left buttock tissue and the leg tissue. The distance between the first bone point and the first adjacency point is less than the distance between the second bone point and the first adjacency point. The method according to any one of claims 1 to 10, wherein, The first object includes animal objects; In the case where the flexible body tissue includes cheek tissue, the creation direction of the first bone corresponds to the outward convex direction of the cheek tissue, wherein the outward convex distance of the first bone point is less than the outward convex distance of the second bone point; In the case where the flexible body tissue includes abdominal tissue, the creation direction of the first bone corresponds to the outward convex direction of the abdominal tissue, wherein the outward convex distance of the first bone point is less than the outward convex distance of the second bone point. In the case where the flexible body tissue includes tentacled tissue, the tentacled tissue grows at a first external surface location of the animal object, the creation direction of the first bone corresponds to the growth direction of the tentacled tissue, wherein the distance between the first bone point and the first external surface location is less than the distance between the first bone point and the first external surface location. The method according to any one of claims 1 to 11, wherein, The step of binding the first skeleton to the first model portion to obtain the skeleton binding data corresponding to the first model portion includes: Obtain the weight data corresponding to the model vertices in the first model part, and the weight data is used to express the degree of motion correlation between the model vertices and the first bone; Using the weight data, the model vertices in the first model part are weighted and bound to the first bone to obtain the bone binding data. The method according to any one of claims 1 to 12, wherein, The step of obtaining the weight data corresponding to the model vertices in the first model part includes: Based on the prop attachment status of the first model part, the weight data corresponding to the model vertices in the first model part is obtained. The weight data is used to indicate the degree of motion association between the model vertices and the first skeleton when props are attached. The method according to any one of claims 1 to 13, wherein, The step of obtaining the weight data corresponding to the model vertices in the first model part based on the prop attachment status of the first model part includes: When the prop attachment status of the first model part indicates that the first model part includes at least two model sub-parts, the first model part is divided into at least three model regions, where there are prop attachment differences between the at least two model sub-parts, and the at least three model regions include a first region corresponding to each of the at least two model sub-parts, and a second region where there is a boundary relationship between adjacent model sub-parts in the at least two model sub-parts. A first weight is assigned to the first region based on the prop attachment status of the model sub-parts; A second weight is assigned to the second region based on the differences in prop attachment between the adjacent model sub-parts; The first weight and the second weight are used as the weight data. The method according to any one of claims 1 to 14, wherein, The step of controlling the first model part based on the first skeletal motion data to obtain the morphological change data of the first model part includes: The first skeleton motion data is weighted by the weight data to obtain the vertex motion data corresponding to the model vertex; Based on the vertex motion data, the model vertices are controlled to perform vertex motion to obtain morphological change data of the first model part, where the model vertices are used to represent the morphology of the flexible body tissue. The method according to any one of claims 1 to 15, wherein, The method further includes: Obtain a second model portion from the at least one model portion, wherein the second model portion is the model portion in the three-dimensional model that participates in performing the first action; A third skeleton is attached to the second model portion, the third skeleton being used to control the volume change of the second model portion when the three-dimensional model performs the first action. A three-dimensional model data processing device, the device comprising: A first acquisition module is used to acquire a three-dimensional model of a first object, the three-dimensional model including at least one model part, the at least one model part including a first model part corresponding to the flexible body tissue of the first object; The calling module is used to call the shape change trigger, which is used to control the shape change of the first model part through the deformation control parameters. The second acquisition module is used to acquire model action data, which is used to control the movement of at least one model part so that the first object performs a first action. The generation module is used to assign values to the deformation control parameters through the shape change trigger based on the model action data, and correspondingly control the first model part to undergo the shape change during the execution of the first action to obtain shape change data. A computer device comprising a processor and a memory, the memory storing at least one program, the at least one program being loaded and executed by the processor to implement the three-dimensional model data processing method as described in any one of claims 1 to 16. A computer-readable storage medium storing at least one piece of program code, the program code being loaded and executed by a processor to implement the three-dimensional model data processing method as described in any one of claims 1 to 16. A computer program product includes a computer program or instructions that, when executed by a processor, implement the three-dimensional model data processing method as described in any one of claims 1 to 16.