Virtual model deformation method and device, equipment, medium and product
By identifying the rigid model in the virtual model and performing global deformation, and then merging it with the flexible model after determining the rigid transformation parameters, the problem of fitting the structural features of rigid components and the flexible model in the deformation of hybrid material models is solved, and efficient character model adaptation is achieved.
Patent Information
- Application Number
- CN202511794741.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-01
- Publication Date
- 2026-05-01
AI Technical Summary
Existing virtual model deformation methods struggle to maintain both the smooth fit of flexible models and the structural features of rigid components when dealing with mixed-material models, resulting in a loss of visual realism and artistic design intent.
By identifying the rigid model in the virtual model, performing global deformation to determine the rigid transformation parameters, and merging it with the flexible model, a virtual model suitable for the target body shape is generated.
It achieves smooth fitting of flexible models and maintenance of structural features of rigid parts, is suitable for deformation of mixed material models, improves efficiency, and is suitable for the production of large-scale character models.
Smart Images

Figure CN121962549A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of computer technology, and specifically to methods, apparatus, equipment, media, and products for transforming virtual models. Background Technology
[0002] In modern digital entertainment and virtual social platforms, providing users with highly customizable characters is a core element for enhancing immersion and personalized experiences. This means that characters not only vary greatly in facial features, but also in body shapes such as height, weight, and muscle mass. However, each digital garment is typically meticulously designed and created by 3D artists for a specific standard body type. When this garment needs to be applied to other non-standard body types, it requires deformation.
[0003] The relevant deformation schemes are generally uniform deformation methods, which often lead to the rigid accessories on the clothing being twisted, stretched or compressed in a way that does not conform to their physical properties, seriously damaging the visual realism of the model and the artistic design intent. Summary of the Invention
[0004] In view of this, this application provides a method, apparatus, device, medium and product for deforming virtual models to solve the problem of difficulty in unifying the deformation of mixed material models.
[0005] In a first aspect, this application provides a method for deforming a virtual model, the method comprising: Obtain the first virtual model and identify the first rigid model in the first virtual model; The first virtual model is globally deformed to obtain an intermediate virtual model; Based on the parameter change information of the first rigid model from the global deformation of the first virtual model to the intermediate virtual model, the rigid transformation parameters of the first rigid model are determined. The second rigid model, obtained by rigidly transforming the first rigid model according to the rigid transformation parameters, is merged with the flexible model in the intermediate virtual model to generate the second virtual model.
[0006] Secondly, this application provides a deformation device for a virtual model, the device comprising: The acquisition module is used to acquire the first virtual model and identify the first rigid model in the first virtual model; A global deformation module is used to perform global deformation on the first virtual model to obtain an intermediate virtual model; The parameter determination module is used to determine the rigid transformation parameters of the first rigid model based on the parameter change information of the first rigid model corresponding to the global deformation from the first virtual model to the intermediate virtual model. The model merging module is used to merge the second rigid model obtained by rigidly transforming the first rigid model according to the rigid transformation parameters with the flexible model in the intermediate virtual model to generate a second virtual model.
[0007] Thirdly, this application provides an electronic device, including: a memory and a processor, which are communicatively connected to each other. The memory stores computer instructions, and the processor executes the computer instructions to perform a modified method of the virtual model of the first aspect or any corresponding embodiment described above.
[0008] Fourthly, this application provides a computer-readable storage medium storing computer instructions for causing a computer to execute a modified method of the virtual model of the first aspect or any corresponding embodiment described above.
[0009] Fifthly, this application provides a computer program product, including computer instructions for causing a computer to execute a modified method of the virtual model of the first aspect or any corresponding embodiment described above.
[0010] The virtual model deformation method provided in this application, based on the global deformation of a first virtual model, retains the flexible model in the intermediate virtual model after deformation. Furthermore, based on the parameter change information of the rigid model, it determines the rigid transformation parameters applicable to the rigid model, and then performs a separate rigid transformation on it based on these parameters. The rigid transformation result is then fused with the flexible model in the intermediate virtual model to obtain a second virtual model suitable for the target body shape. This method ensures smooth fit of flexible models such as cloth while maintaining the structural characteristics of rigid components, making it suitable for the deformation of mixed material models. Moreover, this method enables automatic model deformation, greatly improving efficiency and making it suitable for large-scale character model production scenarios. Attached Figure Description
[0011] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0012] Figure 1 This is a schematic diagram of an application scenario according to an embodiment of the present invention; Figure 2 This is a schematic diagram of the first process of a virtual model deformation method according to an embodiment of the present invention; Figure 3 This is a schematic diagram of a second process for a virtual model deformation method according to an embodiment of the present invention; Figure 4 This is a schematic diagram of a first virtual model according to an embodiment of the present invention; Figure 5 According to an embodiment of the present invention Figure 4 A schematic diagram of a medium rigid component Figure 6 This is a schematic diagram of the result of merging rigid components according to an embodiment of the present invention; Figure 7 This is another schematic diagram of the first virtual model according to an embodiment of the present invention; Figure 8 This is a schematic diagram of a source body type and a target body type according to an embodiment of the present invention; Figure 9 This is a schematic diagram of various target virtual models according to embodiments of the present invention; Figure 10 The deformation result is generated after the source virtual model is globally deformed based on RBF according to an embodiment of the present invention. Figure 11 This is a schematic diagram of a second virtual model according to an embodiment of the present invention; Figure 12 This is a structural block diagram of a deformation device for a virtual model according to an embodiment of the present invention; Figure 13 This is a schematic diagram of the hardware structure of an electronic device according to an embodiment of the present invention. Detailed Implementation
[0013] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0014] It is understood that before using the technical solutions disclosed in the various embodiments of the present invention, users should be informed of the types, scope of use, and usage scenarios of the personal information involved in the present invention and their authorization should be obtained in accordance with relevant laws and regulations through appropriate means.
[0015] The terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Therefore, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of this application, "multiple" means two or more, unless otherwise explicitly specified.
[0016] In the process of digital content creation (DCC) and video game development, it is generally necessary to generate virtual character assets. To provide users with highly customizable characters, clothing models for various body types need to be generated. A common challenge in the industry is balancing the need for diverse character assets with production costs. To address the challenge of adapting standard-body clothing to diverse body types, the industry has explored various technical solutions.
[0017] Option 1: Manual reshaping and adjustment.
[0018] This is the most traditional method, where artists manually adjust tens of thousands of vertices of the clothing model in DCC software to match the new body shape. While this method can guarantee the highest quality, it is extremely inefficient, costly, and difficult to ensure consistency in large-scale production, making it unscalable for large projects.
[0019] Option 2: Skeleton Retargeting.
[0020] This technique indirectly deforms the clothing mesh by scaling and translating bones. However, bone repositioning is essentially a kinematic tool, not a geometric shaping tool. When there are significant differences in body shape, it can lead to severe geometric compression or stretching defects and cannot handle changes in surface details such as muscle bulges, making it unsuitable for precise geometric adaptation tasks.
[0021] Option 3: Physics-based cloth simulation.
[0022] Professional fabric simulation software can make clothing appear as virtual fabric that naturally conforms to the target body shape. However, its main drawback is that it can destroy the original folds and style carefully designed by the artist, resulting in the loss of artistic details. At the same time, the simulation process involves a huge amount of computation, the results are random, and a large amount of human intervention is required.
[0023] Option 4: Global deformation based on radial basis function (RBF).
[0024] As an advanced automation solution, the RBF-based deformation method constructs a smooth and continuous three-dimensional deformation field by establishing a correspondence between control points on the surfaces of the source and target body shapes, and then applies this deformation field to the entire garment model. This method can generate high-quality, smooth fit results that retain wrinkle details for the flexible parts of the garment (such as fabric), greatly improving automation efficiency and quality. However, this introduces undesirable deformations into rigid components.
[0025] Specifically, the core advantage of the RBF method lies in the fact that its constructed deformation function d(x) is a global, smooth interpolation function. This means that any point in space, whether it belongs to fabric or a rigid component (such as a metal button), will have a displacement vector calculated according to this function. This "one-size-fits-all" global effect is crucial for ensuring the continuity and smoothness of fabric parts, but it is disastrous for rigid components embedded in or attached to fabric.
[0026] When an RBF deformation field is applied to a clothing model containing rigid components, the vertices of these rigid components are moved independently, just like the vertices of the fabric. This causes objects that should maintain a rigid structure (i.e., the relative distances and angles between vertices remain unchanged), such as metal badges, plastic buttons, or helmet plates, to twist, bend, shear, or scale in ways that do not conform to their physical properties. This distortion not only destroys visual realism but also violates the artist's original design intent. This problem is a direct byproduct of the "global smoothing" property of the RBF method and is difficult to resolve within the RBF framework.
[0027] Based on this, embodiments of the present invention provide a deformation method for a virtual model, which can effectively protect the geometric integrity of rigid components in the model while achieving high-fidelity automated adaptation to flexible surfaces, thus realizing hybrid deformation.
[0028] As an optional application scenario of this invention, such as Figure 1 As shown, application 101 is installed in terminal device 110, and user 130 can interact with application 101 through terminal device 110 and / or access device of terminal device 110.
[0029] For example, application 101 can be any application, such as DCC software or game software, capable of generating character models. Figure 1 In the application scenario shown, if application 101 is active, the terminal device 110 can display the interface 102 of application 101. The interface 102 may include various pages that application 101 can provide, such as interactive pages, settings pages, query pages, etc.
[0030] In some embodiments, terminal device 110 is communicatively connected to server 120 to provide services to application 101. Terminal device 110 may be a mobile terminal, fixed terminal, or portable terminal, etc., including but not limited to mobile phones, desktop computers, laptop computers, multimedia tablets, e-book devices, gaming devices, or any combination thereof, including accessories and peripherals of these devices or any combination thereof. In some embodiments, terminal device 110 may also support any type of interface, and server 120 may be various types of computing systems or servers capable of providing computing power, including but not limited to mainframes, edge computing nodes, computing devices in cloud environments, etc.
[0031] It should be noted that, Figure 1 This is merely an example of an application scenario and does not limit the scope of protection of this invention.
[0032] According to an embodiment of the present invention, a method for modifying a virtual model is provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Furthermore, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.
[0033] This embodiment provides a method for transforming a virtual model, which can be used in the aforementioned terminal devices or servers. For example, the implementation logic of this method can be executed as a standalone command-line tool, integrated into mainstream DCC software as a plugin, or embedded in a game engine editor; this embodiment does not limit this. Figure 2 This is a flowchart of a virtual model deformation method according to an embodiment of the present invention, such as... Figure 2 As shown, the process includes the following steps.
[0034] Step S201: Obtain the first virtual model and identify the first rigid model in the first virtual model.
[0035] In this embodiment, when a virtual model needs to be transformed to suit characters of different body types, a corresponding source virtual model can be obtained. By processing the source virtual model, a new target virtual model can be obtained. For ease of description, the source virtual model is referred to as the first virtual model, and the target virtual model to be obtained is referred to as the second virtual model.
[0036] The first virtual model can be a clothing model (Mcloth_src). For example, the first virtual model is the original 3D clothing model (in .obj or .fbx format) designed for the source body type. It is a hybrid material model, mainly including flexible models such as clothing, and may also include rigid models such as buttons and accessories. Similarly, the second virtual model is also a clothing model (Mcloth_tgt).
[0037] After obtaining the first virtual model, the rigid components within it are identified to determine the rigid models contained in the first virtual model, i.e., the first rigid models. It can be understood that the number of first rigid models can be one or multiple, depending on the specific circumstances.
[0038] Step S202: Perform global deformation on the first virtual model to obtain the intermediate virtual model.
[0039] In this embodiment, the first virtual model is a virtual model applicable to the source body type. At this time, it is necessary to generate a virtual model (i.e., the second virtual model) applicable to the target body type (e.g., a smaller body type, a larger body type, etc.). Therefore, the first virtual model can be globally deformed according to the source body type and the target body type to initially obtain a virtual model applicable to the target body type, i.e., an intermediate virtual model.
[0040] For example, global deformation of the first virtual model can be achieved based on global deformation such as radial basis functions (RBF), which will not be described in detail in this embodiment.
[0041] For example, when deforming a model, the system input may include a first virtual model, as well as the model mesh corresponding to the source model and the model mesh corresponding to the target model.
[0042] It is understandable that this global deformation method is applicable to the flexible model part. That is, after the first virtual model is globally deformed, the flexible model in the first virtual model can generate a high-quality deformation result that fits the target body shape. In other words, the flexible model in the intermediate virtual model fits the target body shape relatively well.
[0043] However, when the first rigid model in the first virtual model is deformed using methods such as RBF, problems such as distortion generally occur.
[0044] Step S203: Determine the rigid transformation parameters of the first rigid model based on the parameter change information corresponding to the first rigid model from global deformation of the first virtual model to the intermediate virtual model.
[0045] In this embodiment, after the first virtual model is globally deformed to the intermediate virtual model, the parameters of the first rigid model within the first virtual model will change to some extent. For example, parameters such as position and orientation will change, forming corresponding parameter change information. This parameter change information can specifically include the parameters before and after the global deformation, or it can include the amount of parameter change before and after the global deformation, such as the change in position. Based on this parameter change information, relevant parameters that can represent the rigidity change can be determined, i.e., rigid transformation parameters. For example, rigid transformation parameters can include rotation matrices, translation vectors, etc.
[0046] Among them, the rigid transformation parameters correspond one-to-one with the rigid models. That is, if the first virtual model contains multiple first rigid models, then step S203 is executed for each first rigid model to determine the rigid transformation parameters of each rigid model.
[0047] Step S204: The second rigid model obtained by rigidly transforming the first rigid model according to the rigid transformation parameters is merged with the flexible model in the intermediate virtual model to generate the second virtual model.
[0048] In this embodiment, by performing a rigid transformation on the first rigid model according to the rigid transformation parameters, another rigid model that retains the morphological characteristics of the first rigid model, namely the second rigid model, can be obtained. It can be understood that this second rigid model, while retaining the original characteristics of the rigid model, can be applied to the target body shape; that is, the second rigid model can serve as the rigid model in the target virtual model.
[0049] As shown above, the flexible model part in the intermediate virtual model can also match the target body shape relatively well. Therefore, the two are merged, that is, the second rigid model and the flexible model in the intermediate virtual model are merged to obtain the second virtual model suitable for the target body shape.
[0050] The virtual model deformation method provided in this embodiment, based on the global deformation of the first virtual model, retains the flexible model in the intermediate virtual model after deformation. Furthermore, based on the parameter change information of the rigid model, it determines the rigid transformation parameters applicable to the rigid model, and then performs a separate rigid transformation on it based on these parameters. The rigid transformation result is then fused with the flexible model in the intermediate virtual model to obtain a second virtual model suitable for the target body shape. This method ensures smooth fit of flexible models such as cloth while maintaining the structural characteristics of rigid components, making it suitable for the deformation of mixed material models. Moreover, this method enables automatic model deformation, greatly improving efficiency and making it suitable for large-scale character model production scenarios.
[0051] This embodiment provides a method for transforming a virtual model, which can be used in the aforementioned terminal device or server. Figure 3 This is a flowchart of a virtual model deformation method according to an embodiment of the present invention, such as... Figure 3 As shown, the process includes the following steps.
[0052] Step S301: Obtain the first virtual model and identify the first rigid model in the first virtual model.
[0053] Please see details Figure 2 Step S201 of the illustrated embodiment will not be described again here.
[0054] In this embodiment, the system input may include a first virtual model (Mcloth_src), a model mesh corresponding to the source body shape (Mbody_src), and a model mesh corresponding to the target body shape (Mbody_tgt). The goal is to output a second virtual model (Mcloth_tgt) that matches the target body shape.
[0055] In some alternative implementations, step S301, “identifying the first rigid model in the first virtual model,” may include steps A1 to A2.
[0056] Step A1: Based on the identification information of each vertex in the first virtual model, determine the rigid vertices belonging to the rigid model.
[0057] Step A2: Identify each rigid model based on the rigid vertices in the first virtual model.
[0058] In this embodiment, when designing the first virtual model, corresponding identification information can be set for each vertex in the first virtual model. This identification information is used to indicate which part or which vertices of the first virtual model belong to the rigid vertices of the rigid model. Then, after obtaining the second virtual model, the rigid vertices in the first virtual model can be quickly determined based on the identification information therein.
[0059] After identifying all rigid vertices, the first rigid model in the first virtual model can be determined. For example, rigid vertices can be grouped according to their positions, with each group corresponding to a first rigid model.
[0060] For example, the first virtual model can be split into multiple sub-models, distinguished by naming each sub-model as either a rigid or flexible model. Alternatively, a specific channel within the vertices (e.g., the red channel, or R-channel) can be used for labeling. Vertices with an R-channel value greater than or equal to a certain threshold (e.g., 0.9) are considered "rigid vertices," belonging to the rigid model; while vertices with R-channel values below this threshold are considered "flexible vertices," belonging to flexible models such as cloth. This method is intuitive, easy to edit in various DCC software, and the data can be directly stored in standard model file formats (e.g., .fbx).
[0061] Figure 4 A schematic diagram of a certain first virtual model is shown, such as Figure 4 As shown, the first virtual model mainly includes a flexible clothing model and three rigid models of the outer surface. Figure 4 In the diagram, red indicates the rigid model. It can be understood that all three rigid models can be used as the first rigid model.
[0062] Optionally, step A2, "identifying each first rigid model based on the rigid vertices in the first virtual model," may include steps A21 to A22.
[0063] Step A21: Based on the connection relationships between the rigid vertices in the first virtual model, group the rigid vertices to generate at least one set of rigid vertices; any rigid vertex in the set of rigid vertices has a connection relationship with at least one other rigid vertex in the set of rigid vertices.
[0064] In this embodiment, for all rigid vertices in the first virtual model, a corresponding vertex set can be formed, which can be represented in the form of an array. For example, the vertex array records the vertex numbers of all rigid vertices, for example, the vertex array rigid_mask = [1,2,3,4,5,6,7,8…].
[0065] Furthermore, based on the topological structure of each rigid vertex, the connection relationships between each rigid vertex can be determined. That is, for any rigid vertex, it can be determined which or which other rigid vertices it is adjacent to (two points are adjacent if they share an edge), thus determining the connection relationships between each rigid vertex.
[0066] For example, for each rigid vertex in the vertex array `rigid_mask`, we can iterate through them sequentially, querying other vertices connected to a given rigid vertex to determine the connection relationship. This connection relationship can be represented using an array of neighboring vertices. For example, the neighboring vertex array `neighbors` can be represented as: neighbors = [ [1, 2], # Vertex 0 is adjacent to vertices 1 and 2. [0, 2, 3], # Vertex 1 is adjacent to vertices 0, 2, 3 [0, 1, 4], # Vertex 2 is adjacent to vertices 0, 1, 4 [1], # Vertex 3 is adjacent to vertex 1 [2]# Vertex 4 is adjacent to vertex 2 ] Based on the connection relationships (e.g., the neighbor array) corresponding to the first virtual model, it can be determined which rigid vertices are connected. Based on this, groups are formed to obtain at least one set of rigid vertices. It can be understood that the set of rigid vertices includes multiple rigid vertices, and these rigid vertices are connected.
[0067] For example, you can loop through each rigid vertex in the vertex array rigid_mask. For a given rigid vertex, you can query its neighboring vertices in the neighboring vertex array neighbors, and then query the neighboring vertices of that neighboring vertex in turn, and so on, until there are no unqueried connected vertices in the vertex array rigid_mask. At this point, all the queried rigid vertices are marked as an independent component, that is, they can be used as an independent rigid model.
[0068] In this embodiment, the set of vertices grouped according to the hierarchical relationship is called a rigid vertex set, and each rigid vertex set can correspond to a rigid model.
[0069] Step A22: Merge the sets according to the positional relationships between the various rigid vertex sets to generate at least one first rigid model; the first rigid model corresponds to the merged rigid vertex set.
[0070] When creating the first virtual model, a rigid component may be divided into multiple parts. For example, dividing a sword into a hilt and a blade results in two independent rigid components in terms of topology. However, during actual deformation processing, they can function as a single, complete rigid component. Based on this, this embodiment merges the rigid vertex sets according to their positional relationships, ultimately generating the first rigid model required for subsequent processing.
[0071] Optionally, step A22, "merging sets according to the positional relationships between the various rigid vertex sets to generate at least one first rigid model", may include steps A221 to A222.
[0072] Step A221: Determine the axis-aligned bounding box corresponding to the rigid vertex set based on the vertex coordinates of each rigid vertex in the rigid vertex set.
[0073] Step A222: Merge the set of rigid vertices whose axis-aligned bounding boxes are less than a preset distance to generate the corresponding first rigid model.
[0074] In this embodiment, rigid vertex sets that are close to each other generally belong to the same rigid component, and therefore can be merged into a single rigid model. Since rigid vertex sets generally contain a large number of vertices, it is not easy to calculate their positional relationships. In this embodiment, axis-aligned bounding boxes (AABBs) are used to easily and conveniently determine the positions of each rigid vertex set, and thus determine the positional relationships between two rigid vertex sets.
[0075] Specifically, after determining the axis-aligned bounding boxes corresponding to each set of rigid vertices, the distance between each set of axis-aligned bounding boxes can be calculated. If the distance is less than a preset distance, it can be considered that the two sets of axis-aligned bounding boxes are close to each other, and the two sets of rigid vertices are likely to belong to the same rigid model. Therefore, they can be merged into the required first rigid model.
[0076] Figure 5 It shows Figure 4 A schematic diagram of a medium-rigidity model, such as Figure 4 As shown, different colors are used to distinguish the various rigid components initially determined based on their connectivity relationships. Each rigid component corresponds to one of the aforementioned rigid vertex sets. After merging based on their positional relationships, these rigid components can be combined into three, resulting in three first rigid models. The merging result is shown below. Figure 6 As shown. Figure 6 In the diagram, different colors represent different first rigid models, specifically including the first rigid models corresponding to three rigid components: gourd, sword, and shoulder ornament.
[0077] Step S302: Perform global deformation on the first virtual model to obtain the intermediate virtual model.
[0078] Please see details Figure 2 Step S202 of the illustrated embodiment will not be described again here.
[0079] Figure 7 A schematic diagram of the first virtual model is shown. Figure 8 A schematic diagram showing the source and target body shapes is provided. Figure 7 The first virtual model is applicable Figure 8 The source body type is shown. Based on the relationship between the standard source body type and other target body types, the corresponding RBF function can be calculated. Then, the RBF function is used for body type adaptation, thereby obtaining the intermediate virtual model corresponding to each target body type. Specifically, it can be done as follows: Figure 9As shown.
[0080] In this embodiment, leveraging the advantages of global non-rigid deformation methods (such as RBF) in handling flexible surfaces, it is applied to the entire first virtual model to obtain a preliminary intermediate result containing distorted rigid components. It should be understood that this intermediate result serves only as a reference for the target posture of the rigid components, rather than the final form.
[0081] Figure 10 This demonstrates the deformation result generated after globally deforming the source virtual model based on RBF. The virtual weapon, shaped like a sword on the character's back, is a rigid component and should retain its original rigid shape after deformation. However, as... Figure 10 As shown, the rigid virtual weapon deforms severely.
[0082] Step S303: Determine the rigid transformation parameters of the first rigid model based on the parameter change information corresponding to the first rigid model from global deformation of the first virtual model to the intermediate virtual model.
[0083] In this embodiment, the first rigid model contains multiple rigid vertices. For ease of description, the rigid vertices in the first rigid model are referred to as target rigid vertices.
[0084] Furthermore, step S303, "determining the rigid transformation parameters of the first rigid model based on the parameter change information corresponding to the first rigid model from global deformation of the first virtual model to the intermediate virtual model", may include steps S3031 to S3033.
[0085] Step S3031: Determine the first vertex coordinates of each target rigid vertex in the first virtual model to form the first coordinate set.
[0086] In this embodiment, for the first rigid model, the vertex coordinates of each target rigid vertex in the first virtual model can be determined, i.e., the first vertex coordinates, thereby forming a corresponding first coordinate set. It can be understood that this first coordinate set contains the first vertex coordinates of each target rigid vertex.
[0087] For example, for the k-th first rigid model RB k The vertex coordinates p of each rigid vertex can be determined. i (i.e., the coordinates of the first vertex), which in turn forms the corresponding point set P. k That is, the first coordinate set, and P k ={ p i}, where i is the first rigid model RB k Index of rigid vertices.
[0088] Step S3032: Based on the intermediate virtual model, determine the coordinates of the second vertex corresponding to each target rigid vertex after global deformation, forming a second coordinate set.
[0089] In this embodiment, global deformation of the virtual model only changes the position of the vertices, but the vertices before and after deformation still have corresponding relationships; for example, global deformation does not change the number of vertices. After generating the intermediate virtual model, for each target rigid vertex, its new vertex coordinates after deformation can be determined, i.e., the second vertex coordinates, thereby generating the corresponding second coordinate set.
[0090] Similarly, for the j-th first rigid model RB j It is possible to determine the coordinates q of the second vertex corresponding to each of the target rigid vertices. i This leads to the formation of the corresponding point set Q. j That is, the second coordinate set, and Q j ={ q i For example, the coordinates of the target rigid vertex in the intermediate virtual model can be directly used as the coordinates of the second vertex.
[0091] It is understandable that the parameter change information includes the first coordinate set and the second coordinate set mentioned above.
[0092] In some optional implementations, step S3022, "determining the second vertex coordinates corresponding to each target rigid vertex after global deformation based on the intermediate virtual model," may include steps B1 to B2.
[0093] Step B1: For any target rigid vertex, determine the displacement vector of the target rigid vertex before and after global deformation based on the flexible vertices surrounding the target rigid vertex.
[0094] Because rigid components undergo significant deformation after global deformation (e.g., RBF deformation), the accuracy of vertex coordinates corresponding to rigid components in the intermediate virtual model is poor. Therefore, this embodiment uses flexible vertices surrounding the rigid vertex to initially determine the possible location of the deformed target rigid vertex, i.e., the coordinates of the second vertex.
[0095] For a given rigid vertex, multiple flexible vertices surrounding it can be identified. These flexible vertices can be understood as vertices belonging to the flexible portion of the virtual model, i.e., vertices outside the rigid model itself. For example, flexible vertices within a certain range of the rigid vertex can be identified. For each flexible vertex, the changes in its position parameters before and after global deformation can be determined, thereby identifying the displacement vector corresponding to the rigid vertex.
[0096] Optionally, step B1, "determine the displacement vector of the target rigid vertex before and after global deformation based on the flexible vertices around the target rigid vertex", may include steps B11 to B13.
[0097] Step B11: Identify the multiple target flexible vertices in the first virtual model that are closest to the target rigid vertex.
[0098] Step B12: Determine the coordinates of the third vertex of each target flexible vertex in the first virtual model and the coordinates of the fourth vertex in the intermediate virtual model.
[0099] Step B13: Based on the difference between the coordinates of the third and fourth vertices of each target flexible vertex, determine the displacement vectors of the target rigid vertex before and after global deformation.
[0100] In this embodiment, for the i-th target rigid vertex, p i Referring to this rigid vertex, the distance p from the rigid vertex can be found in the first virtual model. i The nearest K flexible vertices n k This forms the neighbor set Ni corresponding to the i-th target rigid vertex, which contains K flexible vertices n. k For ease of description, this flexible vertex will be referred to as the target flexible vertex.
[0101] The value of K can be adjusted according to the density of the virtual model. For example, the denser the number of faces or vertices in the model, the larger the value of K; for example, K=10. It can be understood that K can be a fixed value or a value that can be adaptively adjusted. This embodiment does not limit this.
[0102] For each target flexible vertex n k It is possible to determine the position coordinates of the target flexible vertex n before and after the global deformation from the first virtual model to the intermediate virtual model, i.e., the position coordinates of the target flexible vertex n before deformation. k The coordinates of the third vertex in the first virtual model And the flexible vertex n of the target after deformation k The coordinates of the fourth vertex in the intermediate virtual model .
[0103] Combining K target flexible vertices n k This yields a representation of the target rigid vertex p. i Displacement vector of the average motion trend of the surrounding environment avg ,and: .
[0104] Step B2: Translate the coordinates of the first vertex according to the displacement vector to obtain the coordinates of the second vertex corresponding to the target rigid vertex after global deformation.
[0105] Determining the displacement vector avg Then, based on this displacement vector avg Estimate the target rigid vertex p i In the ideal position after deformation, i.e., the coordinates of the second vertex q i , and q i =p i + avg Furthermore, based on the calculated coordinates q of each second vertex... i Add to the second coordinate set Q j In the end, a complete second coordinate set Q is generated. j .
[0106] In this embodiment, the target rigid vertex can be considered as being "carried" along by the surrounding flexible vertices (such as cloth), and its overall displacement should be consistent with the average displacement of the surrounding flexible vertices. Based on this, a displacement vector that can represent the average motion trend is determined, and then the vertex coordinates of each rigid vertex after deformation are determined, which can more accurately characterize the movement of the rigid vertices after the model is deformed.
[0107] Step S3033: Determine the rigid transformation parameters of the first rigid model based on the positional relationship between the first coordinate set and the second coordinate set.
[0108] In this embodiment, for each first rigid model RB j All of them can yield a one-to-one corresponding set of coordinates, i.e. (P j Q j ).
[0109] For the j-th first rigid model RB j According to its corresponding first coordinate set P j With the second coordinate set Q j This allows us to determine the overall rigidity transformation trend between the two, and thus determine the j-th first rigid model RB. j The corresponding rigid transformation parameters. For example, rigid transformation parameters can include rotation parameters and translation parameters.
[0110] In some optional implementations, step S3033, "determining the rigid transformation parameters of the first rigid model based on the positional relationship between the first coordinate set and the second coordinate set," may specifically include steps C1 to C4.
[0111] Step C1: Decentralize the first and second coordinate sets to generate the corresponding third and fourth coordinate sets.
[0112] Step C2: Determine the covariance matrix between the third coordinate set and the fourth coordinate set.
[0113] Step C3: Perform singular value decomposition on the covariance matrix to obtain the corresponding singular vector matrix.
[0114] Step C4: Determine the rigid transformation parameters of the first rigid model based on the singular vector matrix.
[0115] In this embodiment, determining the rigid transformation parameters is essentially solving the problem of minimizing the cost function. Specifically, for the first coordinate set P... j With the second coordinate set Q j Calculate the corresponding centroids for each point. For example, the arithmetic mean of all coordinate points can be used as the centroid of the corresponding coordinate set.
[0116] For example, the first coordinate set P j center of mass Second coordinate set Q j center of mass They are respectively: , Where N is the number of target rigid vertices in the first rigid model.
[0117] Next, the two point sets are decentered by subtracting the centroid of the point set containing each vertex from its coordinates, resulting in a new point set, the third coordinate set P. j 'and the fourth coordinate set Q j '. Among them, the third coordinate set P j The coordinates of the i-th vertex in ' are The fourth coordinate set Q j The coordinates of the i-th vertex in ' are .
[0118] By decentralizing the coordinate point set, the translation component can be separated, and the rotation can be prioritized to ensure that the rotation relationship can be accurately determined later.
[0119] Determine the third coordinate set P j 'and the fourth coordinate set Q j The covariance matrix H between the two coordinate sets is a 3×3 matrix that represents the rotational correspondence between the two coordinate sets. For example, .
[0120] Singular Value Decomposition (SVD) of the covariance matrix H can be expressed as follows: ; where U and V are 3×3 singular vector matrices, specifically orthogonal matrices, and S is a 3×3 diagonal matrix containing singular values.
[0121] The optimal rotation matrix can be calculated from the two singular vector matrices U and V. ,and .
[0122] Finding the optimal rotation matrix Then, the optimal translation vector It can be calculated using the centroid. For example, .
[0123] By applying each first rigid model RB j By performing the above steps, the optimal rigid transformation parameters corresponding to each first rigid model can be determined, specifically including the optimal rotation matrix. and the optimal translation vector .
[0124] Optionally, a scaling factor for the first rigid model can also be determined and used as a rigid transformation parameter. For example, this scaling factor can be determined directly based on the ratio between the source and target body sizes.
[0125] Step S304: The second rigid model obtained by rigidly transforming the first rigid model according to the rigid transformation parameters is merged with the flexible model in the intermediate virtual model to generate the second virtual model.
[0126] Please see details Figure 2 Step S204 of the illustrated embodiment will not be described again here.
[0127] Optionally, step S304, "merging the second rigid model obtained by rigidly transforming the first rigid model according to the rigid transformation parameters with the flexible model in the intermediate virtual model to generate a second virtual model", may include steps D1 to D3.
[0128] Step D1: Traverse each vertex in the first virtual model.
[0129] Step D2: If the target vertex being traversed is a rigid vertex of the first rigid model, perform a rigid transformation on the vertex coordinates of the target vertex in the first virtual model according to the rigid transformation parameters to obtain the vertex coordinates of the target vertex in the second virtual model.
[0130] Step D3: If the target vertex being traversed is a flexible vertex, use the vertex coordinates of the target vertex in the intermediate virtual model as the vertex coordinates of the target vertex in the second virtual model.
[0131] In this embodiment, by traversing each vertex in the first virtual model, the merging method can be determined based on the vertex attributes (flexible or rigid), thereby determining the final position of each vertex and generating the second virtual model.
[0132] Specifically, a new empty vertex list can be initialized to store the vertex coordinates of the second virtual model (Mcloth_tgt).
[0133] Traverse each vertex in the first virtual model (Mcloth_src). For the target vertex currently being traversed, the vertex type of the target vertex can be determined. For example, it can be checked whether the target vertex belongs to a certain rigid model, or it can be determined directly based on the R channel value of the target vertex.
[0134] If the target vertex is a rigid vertex of the first rigid model, then the final position of the target vertex (i.e., the vertex coordinates in the second virtual model) is determined by the rigid transformation parameters described above. For example, if the target vertex is a rigid vertex... Then, the new coordinates obtained after rigid transformation are... for: Then add the new coordinates to the previously generated vertex list.
[0135] At this point, the original vertex positions from the first virtual model are used, instead of the deformed positions from the intermediate virtual model. This ensures that the geometry of the rigid component is perfectly inherited from the original first virtual model, completely eliminating the deformation introduced by global deformations such as RBF.
[0136] If the target vertex is a vertex of another rigid model, then a rigid transformation can be performed based on the rigid transformation parameters of the other rigid model, which will not be elaborated further.
[0137] If the target vertex is a flexible vertex in the first virtual model, its position in the second virtual model can be directly obtained from the intermediate virtual model. The vertex coordinates of the target vertex in the intermediate virtual model are then added to the previously generated vertex list.
[0138] After traversing all vertices, the second virtual model is obtained. When adding vertex coordinates to the vertex list, the vertices are stored in the vertex list of the second virtual model sequentially according to their original indices in the first virtual model. This ensures that the topology (face information) of the second virtual model remains completely consistent with that of the first virtual model.
[0139] Figure 11 A schematic diagram of the second virtual model is shown, such as Figure 11 As shown, the flexible parts (such as clothing) and rigid parts (such as weapons, ornaments, etc.) can fit the corresponding body shape well, and the rigid parts do not deform.
[0140] The virtual model deformation method provided in this embodiment combines global non-rigid deformation with local rigid transformation correction to achieve automated, high-fidelity adaptation of complex clothing models containing rigid components. Rigid components undergo only rigid transformations in spatial pose (e.g., position, orientation), while their shape, size, and structure remain strictly unchanged, thus accurately preserving the original geometry and structural integrity of the rigid model. Smoothing non-rigid deformation of flexible surfaces in the hybrid material model, along with pose estimation and alignment of rigid objects within it, enables precise comprehensive deformation of the hybrid material model.
[0141] This embodiment also provides a virtual model deformation device for implementing the above embodiments and preferred embodiments; details already described will not be repeated. As used below, the term "module" can refer to a combination of software and / or hardware that performs a predetermined function. Although the device described in the following embodiments is preferably implemented in software, hardware implementation, or a combination of software and hardware, is also possible and contemplated.
[0142] This embodiment provides a deformation device for a virtual model, such as Figure 12 As shown, the device includes: The acquisition module 1201 is used to acquire the first virtual model and identify the first rigid model in the first virtual model; The global deformation module 1202 is used to perform global deformation on the first virtual model to obtain an intermediate virtual model; The parameter determination module 1203 is used to determine the rigid transformation parameters of the first rigid model based on the parameter change information of the first rigid model corresponding to the first virtual model from global deformation to the intermediate virtual model. The model merging module 1204 is used to merge the second rigid model obtained by rigidly transforming the first rigid model according to the rigid transformation parameters with the flexible model in the intermediate virtual model to generate a second virtual model.
[0143] In some alternative implementations, identifying the first rigid model in the first virtual model includes: Based on the identification information of each vertex in the first virtual model, determine the rigid vertices belonging to the rigid model; Based on the rigid vertices in the first virtual model, each first rigid model is identified.
[0144] In some optional implementations, identifying each first rigid model based on the rigid vertices in the first virtual model includes: Based on the connection relationships between the rigid vertices in the first virtual model, the rigid vertices are grouped to generate at least one set of rigid vertices; any rigid vertex in the set of rigid vertices has a connection relationship with at least one other rigid vertex in the set of rigid vertices. The sets are merged according to the positional relationships between the various rigid vertex sets to generate at least one first rigid model; the first rigid model corresponds to the merged rigid vertex set.
[0145] In some optional implementations, the step of merging sets based on the positional relationships between the various rigid vertex sets to generate at least one first rigid model includes: Based on the vertex coordinates of each rigid vertex in the rigid vertex set, determine the axis-aligned bounding box corresponding to the rigid vertex set; The set of rigid vertices whose distance between the axis-aligned bounding boxes is less than a preset distance is merged to generate the corresponding first rigid model.
[0146] In some alternative implementations, the first rigid model includes a plurality of target rigid vertices; The step of determining the rigid transformation parameters of the first rigid model based on the parameter change information corresponding to the first rigid model during global deformation from the first virtual model to the intermediate virtual model includes: Determine the first vertex coordinates of each of the target rigid vertices in the first virtual model to form a first coordinate set; Based on the intermediate virtual model, determine the coordinates of the second vertex corresponding to each of the target rigid vertices after global deformation, and form a second coordinate set; Based on the positional relationship between the first coordinate set and the second coordinate set, the rigid transformation parameters of the first rigid model are determined.
[0147] In some optional implementations, determining the second vertex coordinates corresponding to each of the target rigid vertices after global deformation based on the intermediate virtual model includes: For any target rigid vertex, determine the displacement vector of the target rigid vertex before and after global deformation based on the flexible vertices surrounding the target rigid vertex; The first vertex coordinates are translated according to the displacement vector to obtain the second vertex coordinates corresponding to the target rigid vertex after global deformation.
[0148] In some optional implementations, determining the displacement vector of the target rigid vertex before and after global deformation based on the flexible vertices surrounding the target rigid vertex includes: In the first virtual model, identify the multiple target flexible vertices that are closest to the target rigid vertex; Determine the coordinates of the third vertex of each of the target flexible vertices in the first virtual model, and the coordinates of the fourth vertex in the intermediate virtual model; Based on the difference between the coordinates of the third and fourth vertices of each of the target flexible vertices, the displacement vectors before and after global deformation corresponding to the target rigid vertex are determined.
[0149] In some optional implementations, determining the rigid transformation parameters of the first rigid model based on the positional relationship between the first coordinate set and the second coordinate set includes: Decentralize the first coordinate set and the second coordinate set to generate the corresponding third coordinate set and fourth coordinate set; Determine the covariance matrix between the third coordinate set and the fourth coordinate set; Singular value decomposition is performed on the covariance matrix to obtain the corresponding singular vector matrix; The rigid transformation parameters of the first rigid model are determined based on the singular vector matrix.
[0150] In some optional implementations, the step of merging the second rigid model obtained by rigidly transforming the first rigid model according to the rigid transformation parameters with the flexible model in the intermediate virtual model to generate a second virtual model includes: Traverse each vertex in the first virtual model; If the target vertex being traversed is a rigid vertex of the first rigid model, the vertex coordinates of the target vertex in the first virtual model are rigidly transformed according to the rigid transformation parameters to obtain the vertex coordinates of the target vertex in the second virtual model. When the target vertex being traversed is a flexible vertex, the vertex coordinates of the target vertex in the intermediate virtual model are used as the vertex coordinates of the target vertex in the second virtual model.
[0151] The virtual model deformation device provided in this disclosure can execute the virtual model deformation method provided in any embodiment of this disclosure, and has the corresponding functional modules and beneficial effects for executing the method. Further functional descriptions of the various modules and units described above are the same as in the corresponding embodiments described above, and will not be repeated here.
[0152] Figure 13 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention.
[0153] The following is a detailed reference. Figure 13This diagram illustrates a suitable structural schematic for implementing an electronic device according to embodiments of the present invention. The electronic device may include a processor (e.g., a central processing unit, graphics processor, etc.) 1301, which can perform various appropriate actions and processes according to a program stored in read-only memory (ROM) 1302 or a program loaded from memory 1308 into random access memory (RAM) 1303. The RAM 1303 also stores various programs and data required for the operation of the electronic device. The processor 1301, ROM 1302, and RAM 1303 are interconnected via a bus 1304. An input / output (I / O) interface 1305 is also connected to the bus 1304.
[0154] Typically, the following devices can be connected to I / O interface 1305: input devices 1306 including, for example, touchscreens, touchpads, keyboards, mice, cameras, microphones, accelerometers, gyroscopes, etc.; output devices 1307 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; memory devices 1308 including, for example, magnetic tapes, hard disks, etc.; and communication devices 1309. Communication device 1309 allows electronic devices to communicate wirelessly or wiredly with other devices to exchange data. Although Figure 13 Electronic devices with various devices are shown, but it should be understood that it is not required to implement or have all of the devices shown, and more or fewer devices may be implemented or have instead.
[0155] In particular, according to embodiments of the present invention, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of the present invention include a computer program product comprising a computer program carried on a non-transitory computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via a communication device 1309, or installed from a memory 1308, or installed from a ROM 1302. When the computer program is executed by the processor 1301, it performs the functions defined in the modified method of the virtual model of the embodiments of the present invention.
[0156] Figure 13 The electronic device shown is merely an example and should not be construed as limiting the functionality and scope of the embodiments of the present invention.
[0157] This invention also provides a computer-readable storage medium. The methods described above according to embodiments of the invention can be implemented in hardware or firmware, or implemented as computer code that can be recorded on a storage medium, or implemented as computer code downloaded via a network and originally stored on a remote storage medium or a non-transitory machine-readable storage medium and then stored on a local storage medium. Thus, the methods described herein can be processed by software stored on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. The storage medium can be a magnetic disk, optical disk, read-only memory, random access memory, flash memory, hard disk, or solid-state drive, etc.; further, the storage medium can also include combinations of the above types of memory. It is understood that computers, processors, microprocessor controllers, or programmable hardware include storage components capable of storing or receiving software or computer code. When the software or computer code is accessed and executed by the computer, processor, or hardware, a variation of the virtual model method shown in the above embodiments is implemented.
[0158] A portion of this invention can be applied as a computer program product, such as computer program instructions, which, when executed by a computer, can invoke or provide the methods and / or technical solutions according to the invention through the operation of the computer. Those skilled in the art will understand that the forms in which computer program instructions exist in a computer-readable medium include, but are not limited to, source files, executable files, installation package files, etc. Correspondingly, the ways in which computer program instructions are executed by a computer include, but are not limited to: the computer directly executing the instructions, or the computer compiling the instructions and then executing the corresponding compiled program, or the computer reading and executing the instructions, or the computer reading and installing the instructions and then executing the corresponding installed program. Here, the computer-readable medium can be any available computer-readable storage medium or communication medium accessible to a computer.
[0159] Although embodiments of the invention have been described in conjunction with the accompanying drawings, those skilled in the art can make various modifications and variations without departing from the spirit and scope of the invention, and such modifications and variations all fall within the scope defined by the appended claims.
Claims
1. A method for deforming a virtual model, characterized in that, The method includes: Obtain the first virtual model and identify the first rigid model in the first virtual model; The first virtual model is globally deformed to obtain an intermediate virtual model; Based on the parameter change information of the first rigid model from the global deformation of the first virtual model to the intermediate virtual model, the rigid transformation parameters of the first rigid model are determined. The second rigid model, obtained by rigidly transforming the first rigid model according to the rigid transformation parameters, is merged with the flexible model in the intermediate virtual model to generate the second virtual model.
2. The method according to claim 1, characterized in that, The process of identifying the first rigid model in the first virtual model includes: Based on the identification information of each vertex in the first virtual model, determine the rigid vertices belonging to the rigid model; Based on the rigid vertices in the first virtual model, each first rigid model is identified.
3. The method according to claim 2, characterized in that, The step of identifying each first rigid model based on the rigid vertices in the first virtual model includes: Based on the connection relationships between the rigid vertices in the first virtual model, the rigid vertices are grouped to generate at least one set of rigid vertices; any rigid vertex in the set of rigid vertices has a connection relationship with at least one other rigid vertex in the set of rigid vertices. The sets are merged according to the positional relationships between the various rigid vertex sets to generate at least one first rigid model; the first rigid model corresponds to the merged rigid vertex set.
4. The method according to claim 3, characterized in that, The step of merging sets based on the positional relationships between the various rigid vertex sets to generate at least one first rigid model includes: Based on the vertex coordinates of each rigid vertex in the rigid vertex set, determine the axis-aligned bounding box corresponding to the rigid vertex set; The set of rigid vertices whose distance between the axis-aligned bounding boxes is less than a preset distance is merged to generate the corresponding first rigid model.
5. The method according to claim 1, characterized in that, The first rigid model includes multiple target rigid vertices; The step of determining the rigid transformation parameters of the first rigid model based on the parameter change information corresponding to the first rigid model during global deformation from the first virtual model to the intermediate virtual model includes: Determine the first vertex coordinates of each of the target rigid vertices in the first virtual model to form a first coordinate set; Based on the intermediate virtual model, determine the coordinates of the second vertex corresponding to each of the target rigid vertices after global deformation, and form a second coordinate set; Based on the positional relationship between the first coordinate set and the second coordinate set, the rigid transformation parameters of the first rigid model are determined.
6. The method according to claim 5, characterized in that, The step of determining the second vertex coordinates of each of the target rigid vertices after global deformation based on the intermediate virtual model includes: For any target rigid vertex, determine the displacement vector of the target rigid vertex before and after global deformation based on the flexible vertices surrounding the target rigid vertex; The first vertex coordinates are translated according to the displacement vector to obtain the second vertex coordinates corresponding to the target rigid vertex after global deformation.
7. The method according to claim 6, characterized in that, The step of determining the displacement vector of the target rigid vertex before and after global deformation based on the flexible vertices surrounding the target rigid vertex includes: In the first virtual model, identify the multiple target flexible vertices that are closest to the target rigid vertex; Determine the coordinates of the third vertex of each of the target flexible vertices in the first virtual model, and the coordinates of the fourth vertex in the intermediate virtual model; Based on the difference between the coordinates of the third and fourth vertices of each of the target flexible vertices, the displacement vectors before and after global deformation corresponding to the target rigid vertex are determined.
8. The method according to claim 5, characterized in that, Determining the rigid transformation parameters of the first rigid model based on the positional relationship between the first coordinate set and the second coordinate set includes: Decentralize the first coordinate set and the second coordinate set to generate the corresponding third coordinate set and fourth coordinate set; Determine the covariance matrix between the third coordinate set and the fourth coordinate set; Singular value decomposition is performed on the covariance matrix to obtain the corresponding singular vector matrix; The rigid transformation parameters of the first rigid model are determined based on the singular vector matrix.
9. The method according to claim 1, characterized in that, The step of merging the second rigid model obtained by rigidly transforming the first rigid model according to the rigid transformation parameters with the flexible model in the intermediate virtual model to generate a second virtual model includes: Traverse each vertex in the first virtual model; If the target vertex being traversed is a rigid vertex of the first rigid model, the vertex coordinates of the target vertex in the first virtual model are rigidly transformed according to the rigid transformation parameters to obtain the vertex coordinates of the target vertex in the second virtual model. When the target vertex being traversed is a flexible vertex, the vertex coordinates of the target vertex in the intermediate virtual model are used as the vertex coordinates of the target vertex in the second virtual model.
10. A deformation device for a virtual model, characterized in that, The device includes: The acquisition module is used to acquire the first virtual model and identify the first rigid model in the first virtual model; A global deformation module is used to perform global deformation on the first virtual model to obtain an intermediate virtual model; The parameter determination module is used to determine the rigid transformation parameters of the first rigid model based on the parameter change information of the first rigid model corresponding to the global deformation from the first virtual model to the intermediate virtual model. The model merging module is used to merge the second rigid model obtained by rigidly transforming the first rigid model according to the rigid transformation parameters with the flexible model in the intermediate virtual model to generate a second virtual model.
11. An electronic device, characterized in that, include: A memory and a processor are communicatively connected, the memory storing computer instructions, and the processor executing the computer instructions to perform the deformation method of the virtual model according to any one of claims 1 to 9.
12. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions for causing a computer to perform the deformation method of the virtual model according to any one of claims 1 to 9.
13. A computer program product, characterized in that, Includes computer instructions for causing a computer to perform the deformation method of the virtual model according to any one of claims 1 to 9.