A deformation method and device for uniformly flowing a 2D grid to a 3D cylinder

Through preset arrangement algorithm and offset calculation, 3D grid vertices with uniformly distributed and controllable positions are generated, which solves the problem of unevenness when 2D grids are projected onto 3D cylinders in the prior art, and improves the simulation effect.

CN114742696BActive Publication Date: 2024-12-17GUANGZHOU SHANDI INTELLIGENT CLOTHING TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210277048.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-21
Publication Date
2024-12-17
Estimated Expiration
2042-03-21

AI Technical Summary

Technical Problem

In the existing 3D modeling technology, the method of projecting 2D grids onto 3D cylinders leads to uneven distribution of projection points and uncontrollable position, resulting in poor simulation results or failure.

Method used

The preset arrangement algorithm generates multiple arrangement points for the 3D elliptical cylinder, determines the target arrangement point and the first projection point, controls the movement of the 2D grid center point to coincide with the projection point, calculates the grid vertex offset, and generates the corresponding 3D Mesh vertices ensure uniform distribution and controllable position.

Benefits of technology

The problems of uneven distribution of projection points and uncontrollable position are solved. The generated 3D mesh vertices are uniformly distributed and controllable, avoiding penetration and adhesion problems in simulation and improving the simulation effect.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114742696B_ABST
    Figure CN114742696B_ABST
Patent Text Reader

Abstract

The present application relates to a deformation method and storage medium for uniformly flowing a 2D grid to a 3D cylinder. The method includes: generating multiple arrangement points for a preset 3D elliptical cylinder according to a preset arrangement algorithm; selecting an arrangement point from the multiple arrangement points as a target arrangement point; determining a first projection point of the target arrangement point on an ellipse E, wherein the ellipse E is a cross-sectional line of the 3D elliptical cylinder; determining an eccentric angle of the first projection point on the ellipse E; using the center point of the 2D grid as a grid positioning point, and controlling the movement of the grid positioning point so that the projection point of the grid positioning point on the 3D elliptical cylinder coincides with the position of the first projection point; determining the offset of any grid vertex of the 2D grid relative to the current position of the grid positioning point; determining the second projection point of each grid vertex on the 3D elliptical cylinder according to the offset of each grid vertex; and generating a corresponding 3D grid according to the first projection point and multiple second projection points.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a deformation method, device and storage medium for uniformly flowing a 2D grid to a 3D cylinder. Background Art

[0002] Virtual simulation technology is a product of combining VR virtual reality technology with simulation technology on the basis of the rapid development of information technology such as Internet communication technology. It is a more advanced three-dimensional simulation technology. As a cutting-edge technology, its application field is gradually becoming wider and has a profound impact on various industries in people's lives. Clothing 3D flexible simulation technology started relatively early abroad, and the overall technology development is much ahead of that in China. With the proposal of national independent research and development, industrial power and other strategies, virtual simulation has also developed rapidly in China in recent years. Designers and pattern makers make 2D plates and perform virtual simulation directly on the human body through 3D modeling technology.

[0003] There are two main 3D modeling technology solutions in the prior art. One is to project the 2D mesh onto the 3D cylinder at a specified viewing angle, and then generate an initial 3D mesh and pass it to the simulation for simulation; the other is to project the 2D mesh onto the 3D cylinder in the closest point mode, and then generate an initial 3D mesh and pass it to the simulation for simulation; the disadvantages of these two projection methods are that the projection points are unevenly distributed, the positions of the projection points are uncontrollable, the initial positions of the mesh vertices are offset, the areas close to the mesh surface are very dense, and some areas beyond the elliptical cylinder cannot be calculated to the projection points. If we simulate the unevenly distributed mesh, it will cause the simulation to have bad effects such as penetration and adhesion, or even simulation failure. Summary of the invention

[0004] The purpose of the embodiments of the present application is to provide a deformation method and storage medium for uniformly flowing a 2D grid to a 3D cylinder.

[0005] In order to achieve the above-mentioned object, the first aspect of the present application provides a deformation method for uniformly flowing a 2D grid to a 3D cylinder, comprising:

[0006] Generate multiple arrangement points for a preset 3D elliptical cylinder according to a preset arrangement algorithm;

[0007] Selecting a scheduling point from multiple scheduling points as a target scheduling point;

[0008] Determine a first projection point of the target arrangement point on the ellipse E, wherein the ellipse E is a cross-sectional line of the 3D elliptical cylinder;

[0009] Determine the eccentricity angle of the first projection point on the ellipse E;

[0010] The center point of the 2D grid is used as the grid positioning point, and the grid positioning point is controlled to move so that the projection point of the grid positioning point on the 3D elliptical cylinder coincides with the position of the first projection point;

[0011] Determine the offset of any mesh vertex of a 2D mesh relative to the current position of the mesh anchor point;

[0012] The second projection point of each mesh vertex on the 3D elliptical cylinder is determined according to the offset of each mesh vertex; and the corresponding 3D mesh is generated according to the first projection point and the plurality of second projection points.

[0013] In an embodiment of the present application, determining the first projection point of the target arrangement point on the ellipse E includes:

[0014] The coordinate point of the target arrangement point is obtained; and the point on the ellipse E that is closest to the coordinate point of the target arrangement point is determined as the first projection point of the target arrangement point on the ellipse E.

[0015] In an embodiment of the present application, determining the second projection point of each mesh vertex on the 3D elliptical cylinder according to the offset of each mesh vertex includes: determining multiple parameters of the ellipse E; determining the eccentric angle of the first projection point on the ellipse E according to the coordinates of the first projection point and the multiple parameters; for each mesh vertex, determining the second projection point of the mesh vertex on the 3D elliptical cylinder according to the multiple parameters, the offset and the eccentric angle.

[0016] In the embodiment of the present application, the offset includes an offset in the X direction and an offset in the Y direction, and the second projection point is represented by Vproj (V x ,H,V y ), where Vx is calculated according to formula (1) and V is calculated according to formula (2) y :

[0017]

[0018] Among them, the parametric equation of the ellipse E is: x=acosθ, y=bsinθ, a represents the length of the semi-major axis of the ellipse E, b represents the length of the semi-minor axis of the ellipse E, θA is the eccentric angle of the first projection point on the ellipse E, Voffset_x is the offset of the grid vertex relative to the grid positioning point in the X direction, Voffset_y is the offset of the grid vertex relative to the grid positioning point in the Y direction, and Lc is the circumference of the ellipse E.

[0019] In the embodiment of the present application, H is calculated according to formula (3):

[0020] H=Voffset_y+y1 (3)

[0021] Wherein, y1 is the y-axis value of the first arrangement point.

[0022] In an embodiment of the present application, generating a corresponding 3D mesh according to a first projection point and a plurality of second projection points includes: according to a topological relationship between a 3D elliptical cylinder and a 2D mesh, retopologically generating a corresponding 3D mesh from the first projection point and a plurality of second projection points.

[0023] A second aspect of the present application provides a processor configured to execute the above-mentioned deformation method of uniformly flowing a 2D grid to a 3D cylinder.

[0024] A third aspect of the present application provides a deformation device for uniformly flowing a 2D grid to a 3D cylinder, the device comprising a processor for a deformation method for uniformly flowing a 2D grid to a 3D cylinder.

[0025] A fourth aspect of the present application provides a machine-readable storage medium having instructions stored thereon, which, when executed by a processor, configures the processor to execute the above-mentioned deformation method of uniformly flowing a 2D grid to a 3D cylinder.

[0026] The above deformation method and storage medium for uniformly flowing a 2D grid to a 3D cylinder generate multiple arrangement points for a preset 3D elliptical cylinder according to a preset arrangement algorithm; select an arrangement point from the multiple arrangement points as the target arrangement point; determine the first projection point of the target arrangement point on the ellipse E, wherein the ellipse E is the cross-sectional line of the 3D elliptical cylinder; determine the eccentric angle of the first projection point on the ellipse E; use the center point of the 2D grid as the grid positioning point, and control the movement of the grid positioning point so that the projection point of the grid positioning point on the 3D elliptical cylinder coincides with the position of the first projection point; determine the offset of any grid vertex of the 2D grid relative to the current position of the grid positioning point; determine the second projection point of each grid vertex on the 3D elliptical cylinder according to the offset of each grid vertex; generate the corresponding 3D grid according to the first projection point and multiple second projection points. The method generates a 3D grid with uniform vertex distribution and controllable position, which solves the problems of uneven distribution of projection points, uncontrollable position of projection points, offset of initial position of grid vertices, very dense areas close to the grid surface, and inability to calculate projection points in some areas beyond the elliptical cylinder.

[0027] Other features and advantages of the embodiments of the present application will be described in detail in the subsequent specific implementation section. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] The accompanying drawings are used to provide a further understanding of the embodiments of the present application and constitute a part of the specification. Together with the following specific implementations, they are used to explain the embodiments of the present application, but do not constitute a limitation on the embodiments of the present application. In the accompanying drawings:

[0029] Figure 1 The schematic diagram shows a flow chart of a deformation method for uniformly flowing a 2D grid to a 3D cylinder according to an embodiment of the present application;

[0030] Figure 2 A schematic diagram schematically shows a deformation method for uniformly flowing a 2D grid to a 3D cylinder according to an embodiment of the present application;

[0031] Figure 3 Schematically shows an ellipse schematic diagram according to an embodiment of the present application;

[0032] Figure 4 A schematic diagram of a 2D grid according to an embodiment of the present application is schematically shown;

[0033] Figure 5 A schematic diagram of an elliptical cylinder according to an embodiment of the present application is schematically shown;

[0034] Figure 6 A schematic diagram schematically shows the result of projecting a 2D grid into three dimensions according to an embodiment of the present application;

[0035] Figure 7 A schematic diagram of a 3D grid projected from a 2D grid to a three-dimensional grid according to an embodiment of the present application is shown;

[0036] Figure 8 The internal structure of a computer device according to an embodiment of the present application is schematically shown. DETAILED DESCRIPTION

[0037] The specific implementation of the embodiment of the present application is described in detail below in conjunction with the accompanying drawings. It should be understood that the specific implementation described here is only used to illustrate and explain the embodiment of the present application, and is not used to limit the embodiment of the present application.

[0038] Figure 1 The schematic diagram shows a flow chart of a deformation method for uniformly flowing a 2D grid to a 3D cylinder according to an embodiment of the present application. Figure 1 As shown, in one embodiment of the present application, a deformation method for uniformly flowing a 2D grid to a 3D cylinder is provided, comprising the following steps:

[0039] Step 101 : generating a plurality of arrangement points for a preset 3D elliptical cylinder according to a preset arrangement algorithm.

[0040] Step 102: Select a scheduling point from multiple scheduling points as a target scheduling point.

[0041] Step 103: determine a first projection point of the target arrangement point on the ellipse E, wherein the ellipse E is a cross-section line of a 3D elliptical cylinder.

[0042] Step 104, determining the eccentricity angle of the first projection point on the ellipse E.

[0043] Step 105 , taking the center point of the 2D grid as the grid positioning point, and controlling the movement of the grid positioning point so that the projection point of the grid positioning point on the 3D elliptical cylinder coincides with the position of the first projection point.

[0044] Step 106 , determining the offset of any mesh vertex of the 2D mesh relative to the current position of the mesh anchor point.

[0045] Step 107: determining a second projection point of each mesh vertex on the 3D elliptical cylinder according to the offset of each mesh vertex.

[0046] Step 108: Generate a corresponding 3D grid according to the first projection point and the plurality of second projection points.

[0047] like Figure 2 As shown, a set of arrangement points can be generated on the ellipse according to the specified arrangement algorithm, and the user can see the generated arrangement points through specific software. The user selects an arrangement point from the generated set of arrangement points as the target arrangement point A in the software, and then the processor can determine the projection point of the target arrangement point A on the ellipse. Figure 3 As shown, the point on the ellipse E that is closest to the target arrangement point can be determined as the first projection point of the target arrangement point A on the ellipse.

[0048] Among them, the ellipse E is the cross section of the 3D elliptical cylinder. The eccentric angle of the first projection point on the ellipse E can be further determined, and the eccentric angle corresponding to any point P on the ellipse E can be calculated according to the ellipse parameter equation. Figure 3 As shown, the parameter equation of the ellipse E is x=acosθ, y=bsinθ; a represents the length of the semi-major axis, and b represents the length of the semi-minor axis. The eccentric angle corresponding to point Q after point P moves a distance L along the ellipse E is approximately: Where Lc is the circumference of the ellipse. According to the parametric equation, the coordinates corresponding to point Q can be calculated as (acosθ2, bsinθ2).

[0049] like Figure 4 As shown, the center point of the 2D grid is used as the grid positioning point B (x2, y2), and the minimum rectangular bounding box of the 2D grid is obtained. The center point of the bounding box is taken as the grid positioning point B, and the movement of the grid positioning point B is controlled. The user can operate on the software to make the projection point of the grid positioning point on the 3D elliptical cylinder Cyl coincide with the position of the first projection point, and then the offset of any grid vertex of the 2D grid relative to the current position of the grid positioning point can be determined. Figure 5As shown, a target arrangement point A (x1, y1, z1) can be selected on the 3D elliptical cylinder Cyl. According to the relationship between the elliptical cylinder and the ellipse, the closest point between the target arrangement point A and the ellipse is the projection point of the target arrangement point A on the ellipse. The projection point Aproj (x1, z1) of A on the ellipse can be known. Then the eccentric angle of Aproj on the ellipse E can be calculated: It can then be determined that the offsets of any vertex V (x3, y3) on the 2D grid relative to the grid anchor point B (x2, y2) in the X and Y directions are: Voffset_x = x3-x2; Voffset_y = y3-y2.

[0050] According to the offsets Voffset_x and Voffset_y of vertex V relative to the grid anchor point B, the projection point Vproj (Vx, H, Vy) of vertex V on the elliptical cylinder Cyl can be calculated, and Voffset_x is set to the moving distance L of vertex V on the ellipse E relative to Aproj; the calculation formula is as follows Set Voffset_y as the vertical offset of vertex V on the elliptical cylinder Cyl relative to the target arrangement point A; H = Voffset_y + y1. By repeating the calculation, the projection points of all vertices and calculation orders of the 2D mesh on the elliptical cylinder Cyl can be determined, and all mesh vertices can be projected onto the surface of the 3D cylinder Cyl. Finally, a 3D mesh can be generated, such as Figure 7 shown.

[0051] In one embodiment, determining the first projection point of the target arrangement point on the ellipse E includes: obtaining the coordinate point of the target arrangement point; and determining the point on the ellipse E that is closest to the coordinate point of the target arrangement point as the first projection point of the target arrangement point on the ellipse E.

[0052] A set of arrangement points is generated on the elliptical cylinder according to the specified arrangement algorithm. The user can see the generated arrangement points in the software. The user selects an arrangement point from the generated set of arrangement points in the software as the target arrangement point to obtain the coordinate point of the target arrangement point, and the point on the ellipse E that is closest to the coordinate point of the target arrangement point is determined as the first projection point of the target arrangement point on the ellipse E.

[0053] In one embodiment, determining the second projection point of each mesh vertex on the 3D elliptical cylinder based on the offset of each mesh vertex includes: determining multiple parameters of the ellipse E; determining the eccentric angle of the first projection point on the ellipse E based on the coordinates of the first projection point and the multiple parameters; for each mesh vertex, determining the second projection point of the mesh vertex on the 3D elliptical cylinder based on the multiple parameters, the offset and the eccentric angle.

[0054] Determining the second projection point of each mesh vertex on the 3D elliptical cylinder according to the offset of each mesh vertex includes: determining multiple parameters of the ellipse E. Figure 3 As shown, the specific parameters include: the length of the semi-major axis is a, the length of the semi-minor axis is b, the circumference of the ellipse is Lc, the x-axis of any point on the ellipse is x=acosθ, the y-axis is y=bsinθ, the first arrangement point A(x1,y1,z1) and the first projection point Aproj(x1,z1) on the 3D elliptical cylinder Cyl are selected, and the eccentric angle of the projection point Aproj on the ellipse E is calculated: like Figure 4 As shown; select the 2D grid center point B (x2, y2) as the 2D grid positioning point, and make the projection point of B on the elliptical cylinder Cyl coincide with the first arrangement point A; the offsets of the second vertex V (x3, y3) on the 2D grid relative to B in the X and Y directions are: Voffset_x = x3-x2; Voffset_y = y3-y2; according to the offsets Voffset_x and Voffset_y of the vertex V relative to B, the second projection point Vproj (Vx, H, Vy) of the second vertex V on the elliptical cylinder Cyl, Voffset_x is set to the moving distance L of V on the ellipse E relative to Aproj; Voffset_y is set to the vertical offset calculation formula of V on the elliptical cylinder Cyl relative to A as follows:

[0055] In one embodiment, the offset includes an offset in the X direction and an offset in the Y direction, and the second projection point is represented by Vproj (V x ,H,V y ), where Vx is calculated according to formula (1) and V is calculated according to formula (2) y :

[0056]

[0057] Among them, the parametric equation of the ellipse E is: x=acosθ, y=bsinθ. a represents the length of the semi-major axis of the ellipse E, b represents the length of the semi-minor axis of the ellipse E, θA is the eccentric angle of the first projection point on the ellipse E, Voffset_x is the offset of the mesh vertex relative to the mesh positioning point in the X direction, Voffset_y is the offset of the mesh vertex relative to the mesh positioning point in the Y direction, and Lc is the circumference of the ellipse E. When calculating the second projection point, the offset of the second projection point and the first projection point can be calculated to determine the second projection point. The offset includes the offset in the X direction and the offset in the Y direction. The second projection point is represented by Vproj(V x ,H,V y ).

[0058] In one embodiment, H is calculated according to formula (3):

[0059] H=Voffset_y+y1 (3)

[0060] Wherein, y1 is the y-axis coordinate value of the first arrangement point.

[0061] In one embodiment, generating a corresponding 3D mesh according to the first projection point and the plurality of second projection points includes: retopologically generating a corresponding 3D mesh from the first projection point and the plurality of second projection points according to a topological relationship between the 3D elliptical cylinder and the 2D mesh.

[0062] Generating a corresponding 3D mesh according to a first projection point and a plurality of second projection points includes: according to a topological relationship between a 3D elliptical cylinder and a 2D mesh, retopologically generating a corresponding 3D mesh from the first projection point and the plurality of second projection points; for example; selecting a 3D arrangement point as A, selecting a 2D mesh, recording a positioning point of the 2D mesh as B, mapping B to A, obtaining a spatial transformation matrix mapping B to A as Mat, traversing all mesh vertices on the 2D mesh as Vi, calculating the offset between Vi and B in the X and Y directions, calculating the three-dimensional vertex positions of all mesh vertices Vi projected onto the 3D cylinder according to Mat and the offset, and after calculating all three-dimensional vertices, retopologically generating a 3D mesh according to the topological relationship of the 2D mesh, which refers to the relationship between points, surfaces, and bodies of the mesh, such as Figure 6 shown.

[0063] An embodiment of the present invention provides a processor, which is used to run a program, wherein the program executes the above-mentioned deformation method of uniformly flowing a 2D grid to a 3D cylinder when running.

[0064] In one embodiment, a deformation device for uniformly flowing a 2D grid to a 3D cylinder is provided, and the deformation device for uniformly flowing a 2D grid to a 3D cylinder includes a processor.

[0065] An embodiment of the present invention provides a storage medium on which a program is stored. When the program is executed by a processor, the above-mentioned deformation method of uniformly flowing a 2D grid to a 3D cylinder is implemented.

[0066] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Figure 8As shown. The computer device includes a processor A01, a network interface A02, a display screen A04, an input device A05 and a memory (not shown in the figure) connected through a system bus. Among them, the processor A01 of the computer device is used to provide computing and control capabilities. The memory of the computer device includes an internal memory A03 and a non-volatile storage medium A06. The non-volatile storage medium A06 stores an operating system B01 and a computer program B02. The internal memory A03 provides an environment for the operation of the operating system B01 and the computer program B02 in the non-volatile storage medium A06. The network interface A02 of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor A01, a real-time detection method for fabric is implemented. The display screen A04 of the computer device can be a liquid crystal display screen or an electronic ink display screen, and the input device A05 of the computer device can be a touch layer covered on the display screen, or a key, trackball or touchpad set on the computer device shell, or an external keyboard, touchpad or mouse, etc.

[0067] Those skilled in the art will understand that Figure 8 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0068] An embodiment of the present invention provides a device, the device including a processor, a memory, and a program stored in the memory and executable on the processor, and when the processor executes the program, the following steps are implemented:

[0069] Generate multiple arrangement points for a preset 3D elliptical cylinder according to a preset arrangement algorithm; select an arrangement point from the multiple arrangement points as a target arrangement point; determine a first projection point of the target arrangement point on an ellipse E, wherein the ellipse E is a cross-sectional line of the 3D elliptical cylinder; determine an eccentric angle of the first projection point on the ellipse E; use a center point of a 2D grid as a grid positioning point, and control the movement of the grid positioning point so that the projection point of the grid positioning point on the 3D elliptical cylinder coincides with the position of the first projection point; determine an offset of any grid vertex of the 2D grid relative to a current position of the grid positioning point; determine a second projection point of each grid vertex on the 3D elliptical cylinder according to the offset of each grid vertex; and generate a corresponding 3D grid according to the first projection point and multiple second projection points.

[0070] In one embodiment, determining a first projection point of the target arrangement point on the ellipse E includes:

[0071] The coordinate point of the target arrangement point is obtained; and the point on the ellipse E that is closest to the coordinate point of the target arrangement point is determined as the first projection point of the target arrangement point on the ellipse E.

[0072] In one embodiment, determining the second projection point of each mesh vertex on the 3D elliptical cylinder based on the offset of each mesh vertex includes: determining multiple parameters of the ellipse E; determining the eccentric angle of the first projection point on the ellipse E based on the coordinates of the first projection point and the multiple parameters; for each mesh vertex, determining the second projection point of the mesh vertex on the 3D elliptical cylinder based on the multiple parameters, the offset and the eccentric angle.

[0073] In one embodiment, the offset includes an offset in the X direction and an offset in the Y direction, and the second projection point is represented by Vproj (V x ,H,V y ), where Vx is calculated according to formula (1) and V is calculated according to formula (2) y :

[0074]

[0075] Among them, the parametric equation of the ellipse E is: x=acosθ, y=bsinθ, a represents the length of the semi-major axis of the ellipse E, b represents the length of the semi-minor axis of the ellipse E, θA is the eccentric angle of the first projection point on the ellipse E, Voffset_x is the offset of the mesh vertex relative to the mesh positioning point in the X direction, Voffset_y is the offset of the mesh vertex relative to the mesh positioning point in the Y direction, and Lc is the circumference of the ellipse E.

[0076] In one embodiment, H is calculated according to formula (3):

[0077] H=Voffset_y+y1 (3)

[0078] Wherein, y1 is the y-axis value of the first arrangement point.

[0079] In one embodiment, generating a corresponding 3D mesh according to the first projection point and the plurality of second projection points includes: retopologically generating a corresponding 3D mesh from the first projection point and the plurality of second projection points according to a topological relationship between the 3D elliptical cylinder and the 2D mesh.

[0080] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented in one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that include computer-usable program code.

[0081] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0082] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0083] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0084] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.

[0085] The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. The memory is an example of a computer-readable medium.

[0086] Computer readable media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include temporary computer readable media (transitory media), such as modulated data signals and carrier waves.

[0087] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.

[0088] The above are only embodiments of the present application and are not intended to limit the present application. For those skilled in the art, the present application may have various changes and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included within the scope of the claims of the present application.

Claims

1. A deformation method for uniformly flowing a 2D grid to a 3D cylinder, which is applied to simulate a 2D plate on a human body through 3D modeling technology, characterized in that: The method comprises: Generate multiple arrangement points for a preset 3D elliptical cylinder according to a preset arrangement algorithm; Selecting a scheduling point from the multiple scheduling points as a target scheduling point; Determine a first projection point of the target arrangement point on the ellipse E, wherein the ellipse E is a cross-sectional line of the 3D elliptical cylinder; Determine the eccentric angle of the first projection point on the ellipse E; Taking the center point of the 2D grid as a grid positioning point, and controlling the movement of the grid positioning point so that the projection point of the grid positioning point on the 3D elliptical cylinder coincides with the position of the first projection point; Determine an offset of any mesh vertex of the 2D mesh relative to a current position of the mesh anchor point; Determine the second projection point of each mesh vertex on the 3D elliptical cylinder according to the offset of each mesh vertex; A corresponding 3D grid is generated according to the first projection point and the plurality of second projection points.

2. The method according to claim 1, characterized in that Determining the first projection point of the target arrangement point on the ellipse E comprises: Obtaining the coordinates of the target arrangement point; The point on the ellipse E that is closest to the coordinate point of the target arrangement point is determined as the first projection point of the target arrangement point on the ellipse E.

3. The method according to claim 1, characterized in that Determining the second projection point of each mesh vertex on the 3D elliptical cylinder according to the offset of each mesh vertex includes: Determining a plurality of parameters of the ellipse E; Determine the eccentric angle of the first projection point on the ellipse E according to the coordinates of the first projection point and the multiple parameters; For each mesh vertex, a second projection point of the mesh vertex on the 3D elliptical cylinder is determined according to the multiple parameters, the offset, and the eccentric angle.

4. The method according to claim 3, characterized in that The offset includes an offset in the X direction and an offset in the Y direction. The second projection point is represented by Vproj (V x ,H,V y ), where Vx is calculated according to formula (1) and V is calculated according to formula (2). y And H is calculated according to formula (3): H = Voffset_y + y1 (3); 9 Among them, the parametric equation of the ellipse E is: x=acosθ, y=bsinθ, a represents the length of the semi-major axis of the ellipse E, b represents the length of the semi-minor axis of the ellipse E, θA is the eccentric angle of the first projection point on the ellipse E, Voffset_x is the offset of the grid vertex relative to the grid positioning point in the X direction, Voffset_y is the offset of the grid vertex relative to the grid positioning point in the Y direction, Lc is the circumference of the ellipse E; y1 is the y-axis value of the first arrangement point.

5. The method according to claim 1, characterized in that Generating a corresponding 3D grid according to the first projection point and the plurality of second projection points comprises: According to the topological relationship between the 3D elliptical cylinder and the 2D mesh, the first projection point and the plurality of second projection points are retopologically regenerated to generate a corresponding 3D mesh.

6. A deformation device for uniformly flowing a 2D grid to a 3D cylinder, characterized in that: comprising a processor; the processor being configured to execute the method according to any one of claims 1-5.

7. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 5 are implemented.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 5 are implemented.

Citation Information

Patent Citations

  • Three-dimensional human body multi-gesture modeling method by adopting free-hand sketches

    CN102831638A

  • Image processing method and device

    CN107180406A