CN113076571A - Three-dimensional clothes real-time simulation editing method and system - Google Patents
Three-dimensional clothes real-time simulation editing method and system Download PDFInfo
- Publication number
- CN113076571A CN113076571A CN202110411454.8A CN202110411454A CN113076571A CN 113076571 A CN113076571 A CN 113076571A CN 202110411454 A CN202110411454 A CN 202110411454A CN 113076571 A CN113076571 A CN 113076571A
- Authority
- CN
- China
- Prior art keywords
- clothes
- dimensional
- editing
- model
- simulation
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
- 238000004088 simulation Methods 0.000 title claims abstract description 96
- 238000000034 method Methods 0.000 title claims abstract description 46
- 238000013507 mapping Methods 0.000 claims description 6
- 230000008569 process Effects 0.000 abstract description 9
- 238000010586 diagram Methods 0.000 description 5
- 238000013461 design Methods 0.000 description 3
- 238000005516 engineering process Methods 0.000 description 3
- 238000004519 manufacturing process Methods 0.000 description 3
- 238000004364 calculation method Methods 0.000 description 2
- 230000007547 defect Effects 0.000 description 2
- 238000011161 development Methods 0.000 description 2
- 230000000694 effects Effects 0.000 description 2
- 230000002452 interceptive effect Effects 0.000 description 2
- 238000005457 optimization Methods 0.000 description 2
- 239000002245 particle Substances 0.000 description 2
- 238000009877 rendering Methods 0.000 description 2
- 238000005452 bending Methods 0.000 description 1
- 238000011960 computer-aided design Methods 0.000 description 1
- 238000001514 detection method Methods 0.000 description 1
- 230000006872 improvement Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000002715 modification method Methods 0.000 description 1
- 238000000053 physical method Methods 0.000 description 1
- 238000012545 processing Methods 0.000 description 1
- 230000000750 progressive effect Effects 0.000 description 1
- 238000009958 sewing Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F30/00—Computer-aided design [CAD]
- G06F30/10—Geometric CAD
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F30/00—Computer-aided design [CAD]
- G06F30/20—Design optimisation, verification or simulation
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F2113/00—Details relating to the application field
- G06F2113/12—Cloth
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02P—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
- Y02P90/00—Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
- Y02P90/30—Computing systems specially adapted for manufacturing
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Geometry (AREA)
- Evolutionary Computation (AREA)
- Computer Hardware Design (AREA)
- General Engineering & Computer Science (AREA)
- Pure & Applied Mathematics (AREA)
- Mathematical Optimization (AREA)
- Mathematical Analysis (AREA)
- Computational Mathematics (AREA)
- Processing Or Creating Images (AREA)
Abstract
The invention discloses a real-time simulation editing method and a real-time simulation editing system for three-dimensional clothes. The method comprises the following steps: reading and analyzing a clothes two-dimensional model file to obtain the information of a clothes two-dimensional model outline segment; modeling the clothes on a logic and data structure by utilizing a hierarchical structure model based on the two-dimensional model outline line segment information of the clothes to obtain a clothes model; generating a simulation triangular mesh based on the fixed background triangular mesh and the contour line; performing physical simulation on the clothes model on the human body model based on the simulation triangular mesh; editing clothes in a three-dimensional space based on a physical simulation result to obtain an editing vector; the laundry model is updated based on the edit vector. The user can edit the clothes in real time in the three-dimensional space, and meanwhile, an accurate two-dimensional patch type is obtained. The method for updating the clothes grid based on the fixed background triangular grid can not only ensure the real-time performance of the simulation speed, but also ensure that the physical simulation parameters of the clothes cannot be changed in the editing process.
Description
Technical Field
The invention relates to the field of computer aided design, in particular to a three-dimensional clothes real-time simulation editing method and a three-dimensional clothes real-time simulation editing system.
Background
With the rapid development of social economy and the improvement of living standard, the requirements of people on clothes are also improved. Besides basic functions of warm keeping, comfort and the like, people put higher demands on the shape and fashion sense of clothes. Since the body size and the aesthetic value of each person are different, the traditional factory-stylized clothing making process is difficult to meet the personalized dressing requirement, and therefore, the personal clothing customization aiming at the individual will become the mainstream mode of the future clothing manufacturing industry. Meanwhile, with the continuous development of computer technology, the CAD technology is widely applied to various industries. In the field of garment design and manufacture, garment CAD software helps a garment designer to complete the whole manufacturing process of garment design, tailoring, modeling and fitting on a computer, and design efficiency and product quality are obviously improved.
The existing clothing CAD software needs a clothing designer to edit and modify a clothing model file in a two-dimensional model space, then clothing simulation try-on is carried out in a three-dimensional simulation space, and iterative modification is carried out until the required effect is completed. The process needs certain clothing plate making knowledge and industry experience, and has low efficiency, and is difficult to be completed by common users.
The traditional method for editing the clothes grid in the three-dimensional space needs to firstly deform the three-dimensional grid, carry out two-dimensional plane expansion on the deformed triangular grid to obtain a deformed two-dimensional model, then carry out stitching simulation on the expanded model again to obtain a secondary simulation result, and finally carry out residual iterative optimization on the three-dimensional grid subjected to primary simulation and secondary simulation to obtain a final two-dimensional accurate model. However, the process involves numerical optimization, and the single-frame calculation is too long in time consumption to meet the requirement of real-time editing software. In addition, the method can only edit the clothes grids with fixed mass points, and cannot meet the requirement of high-density dynamic grid topology.
Therefore, the existing clothes editing technology cannot meet the requirement of realizing interactive real-time simulation editing in a three-dimensional space.
Disclosure of Invention
The method aims to solve the problems that in the prior art, the three-dimensional clothes editing speed is low and the high-density dynamic mesh topology cannot be realized. The invention provides a real-time simulation editing method and a real-time simulation editing system for three-dimensional clothes.
In order to achieve the purpose, the invention provides the following scheme:
a real-time simulation editing method for three-dimensional clothes comprises the following steps:
reading and analyzing a clothes two-dimensional model file to obtain the information of a clothes two-dimensional model outline segment;
modeling the clothes on a logic and data structure by utilizing a hierarchical structure model based on the two-dimensional model outline segment information of the clothes to obtain a clothes model; the clothes model comprises a two-dimensional model surface patch and a three-dimensional grid; the two-dimensional layout patch comprises a fixed background triangular mesh and a contour, the fixed background triangular mesh comprises mesh points and triangles, and the contour comprises contour points and contour lines;
generating a simulated triangular mesh based on the fixed background triangular mesh and the contour;
performing physical simulation on the clothes model on a human body model based on the simulation triangular mesh;
editing clothes in a three-dimensional space based on a physical simulation result to obtain an editing vector;
updating the clothing model based on the edit vector.
Further, the two-dimensional layout patch and the three-dimensional mesh have the same topology and index number.
Further, the method for generating the fixed background triangular mesh comprises the following steps:
acquiring a maximum rectangular bounding box of the contour point set;
generating a fixed background grid rectangle based on the maximum rectangle bounding box; the center of the fixed background grid rectangle is the center of the maximum rectangular bounding box, and the length and the width of the fixed background grid rectangle are respectively twice the length and the width of the maximum rectangular bounding box;
uniformly inserting grid points in the inner part of the fixed background grid in the transverse direction and the longitudinal direction at a set grid density;
and carrying out background grid triangulation on the fixed background grid rectangle by taking the inserted grid points as constraint points to obtain a fixed background triangular grid.
Further, the generating a simulated triangular mesh based on the fixed background triangular mesh and the contour specifically includes:
determining a clothes outline polygon based on the clothes two-dimensional model outline line segment information;
obtaining triangles in the fixed background triangular mesh positioned inside the clothes outline polygon as a first triangle set
Connecting the interpolation points of the contour lines with the grid points in the fixed background triangular grid to carry out edge contour grid triangularization to obtain a triangular set generated by the interpolation points of the contour lines, wherein the triangular set is a second triangular set;
and taking the union of the first triangle set and the second triangle set as a simulation triangular mesh.
Further, the edge contour mesh triangularization specifically includes:
acquiring line segments formed by adjacent contour points in the clothes contour polygon;
acquiring a triangle set intersected with the line segment in the fixed background triangular mesh to obtain an intersected triangle set;
connecting the starting point of the line segment with all vertexes, which are positioned inside the clothes outline polygon, in the intersected triangle set to form a first triangle;
connecting the end point of the line segment, the starting point and the grid point with the minimum included angle with the line segment to form a second triangle;
and taking the union of the first triangle and the second triangle as a simulation triangle formed by the line segments.
Further, the physically simulating the clothing model on the human body model based on the simulated triangular mesh specifically includes:
placing the simulated triangular mesh in an initial position relative to a human body model;
establishing a spring-mass point model according to the mesh topological connection of the simulation triangular mesh;
and performing simulation on the clothes model on the human body model by adopting a physical-based method based on the spring-mass point model.
Further, the editing the clothes in the three-dimensional space based on the physical simulation result to obtain an editing vector specifically includes:
selecting a three-dimensional editing unit needing to be operated in a three-dimensional space based on a simulation result;
editing the selected three-dimensional editing unit in a three-dimensional space to obtain a three-dimensional editing vector;
and mapping the three-dimensional editing vector to an editing unit corresponding to the two-dimensional layout space to obtain a two-dimensional editing vector.
Further, the updating the clothing model based on the editing vector specifically includes:
modifying and updating a two-dimensional editing unit in a two-dimensional space according to the two-dimensional editing vector;
updating grids in the two-dimensional layout based on the updated editing unit;
obtaining a current frame newly added grid point set based on the grid in the updated two-dimensional version;
for each newly added grid point, determining an adjacent effective point and a relative position vector;
and calculating the initial position of the newly added grid point in the three-dimensional space according to the adjacent effective point and the relative position vector, and updating the three-dimensional grid.
The invention also provides a three-dimensional clothes real-time simulation editing system, which comprises:
and the clothes two-dimensional model outline segment information acquisition module is used for reading and analyzing the clothes two-dimensional model file and acquiring the clothes two-dimensional model outline segment information.
The clothes model building module is used for modeling clothes on a logic and data structure by utilizing a hierarchical structure model based on the two-dimensional model outline segment information of the clothes to obtain a clothes model; the clothes model comprises a two-dimensional model surface patch and a three-dimensional grid; the two-dimensional layout patch comprises a fixed background triangular mesh and a contour, the fixed background triangular mesh comprises mesh points and triangles, and the contour comprises contour points and contour lines;
the simulation triangular network generation module is used for generating a simulation triangular mesh based on the fixed background triangular mesh and the outline;
the physical simulation module is used for carrying out physical simulation on the clothes model on a human body model based on the simulation triangular mesh;
the editing module is used for editing clothes in a three-dimensional space based on a physical simulation result to obtain an editing vector;
an update module to update the clothing model based on the edit vector.
According to the specific embodiment provided by the invention, the invention discloses the following technical effects:
the invention provides a three-dimensional clothes real-time simulation editing method and a three-dimensional clothes real-time simulation editing system aiming at the defects and shortcomings of the existing three-dimensional clothes editing, so that a user can edit clothes in a three-dimensional space in real time and obtain an accurate two-dimensional surface patch type. The method for updating the clothes grid based on the fixed background triangular grid can not only ensure the real-time performance of the simulation speed, but also ensure that the physical simulation parameters of the clothes cannot be changed in the editing process.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings needed to be used in the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings without inventive exercise.
FIG. 1 is a flow chart of a real-time simulation editing method for three-dimensional clothes according to an embodiment of the present invention;
FIG. 2 is a schematic view of a hierarchical structure of a garment;
FIG. 3 is a schematic representation of a contour segment;
FIG. 4 is a schematic diagram of a simulated triangular mesh generation;
FIG. 5 is a schematic diagram of mesh contour triangularization;
FIG. 6 is a schematic diagram of physical simulation;
FIG. 7 is a schematic diagram of a three-dimensional edit vector;
FIG. 8 is a diagram illustrating an edit vector mapping.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
In order to make the aforementioned objects, features and advantages of the present invention comprehensible, embodiments accompanied with figures are described in further detail below.
As shown in fig. 1, a real-time simulation editing method for three-dimensional clothes includes the following steps:
step 101: and reading and analyzing the clothes two-dimensional model file to obtain the clothes two-dimensional model outline line segment information.
The two-dimensional version file format of the clothes is a DXF file, and the DXF file contains all information representing the contour, including contour points and contour line segments; the contour line segment in the DXF file is divided into a straight line segment and a curve segment, and the contour point is divided into a line segment endpoint and a line segment curvature control point. Each line segment is indexed at the same time.
Step 102: modeling the clothes on a logic and data structure by utilizing a hierarchical structure model based on the two-dimensional model outline segment information of the clothes to obtain a clothes model; the clothes model comprises a two-dimensional model surface patch and a three-dimensional grid; the two-dimensional layout patch comprises a fixed background triangular mesh and a contour, the fixed background triangular mesh comprises mesh points and triangles, and the contour comprises contour points and contour lines.
Modeling the clothes on a logic and data structure by using a hierarchical structure model according to the two-dimensional layout contour line segment information of the clothes in the step 101, as shown in fig. 2: the clothes model comprises a two-dimensional model patch and a three-dimensional grid, the two-dimensional model patch and the three-dimensional grid meet the same topological structure and index number, the two-dimensional model patch comprises a fixed background triangular grid and a contour, the fixed background triangular grid comprises a grid point and a triangle, and the contour comprises a contour point and a contour line.
The method for generating the fixed background triangular mesh comprises the following steps: a) acquiring a maximum rectangular bounding box bbox of the contour point set; b) taking the center of the bbox as the center, taking twice of the length and width of the bbox as the length and width, and generating a fixed background grid rectangle based on the maximum rectangle bounding box; c) inserting grid points uniformly in the horizontal direction and the vertical direction in the background grid rectangle according to the set grid density; d) and triangularizing the background grid by taking the inserted grid points as constraint points to finally obtain a fixed background triangular grid.
Wherein, the contour line segment is represented by a cubic Bezier curve, as shown in FIG. 3: each curve consists of a starting point s, an end point e, an interpolation point set { P }, control points c1 and c2, the size of the interpolation point set is N, and the coordinates of the ith interpolation point are as follows:
a straight line can be regarded as a special form of a curve, with the start point, end point, control point and interpolation point being on a straight line.
Step 103: and generating a simulation triangular mesh based on the fixed background triangular mesh and the contour.
The physical simulation requires a clothing triangular mesh, and as shown in fig. 4, the specific process of generating the clothing simulated triangular mesh is as follows:
step 1031: as shown in fig. 4 (a): and (3) judging whether each grid point in the fixed background triangular grid is positioned inside the clothes outline polygon (the clothes outline polygon is determined based on the clothes two-dimensional layout outline line segment information) in parallel by using the GPU, and obtaining the grid points positioned inside the clothes outline polygon as a particle set for subsequent simulation and rendering, wherein the internal points in the graph (a) are black, and the external points are gray.
The method for judging whether the grid points are positioned in the outline polygon comprises the following steps: respectively leading a ray L to the horizontal axis and the vertical axis of a grid plane from a grid point needing to be judgedxAnd LyRespectively determine Lx,LyWhether each line segment of the outline polygon is intersected or not is obtainedxAnd LyThe number of the crossed line segments is N respectivelyxAnd NyIf N is presentxAnd NyIf the grid points are all even numbers, the grid points are positioned outside the outline polygon; otherwise, this grid point is located inside the outline polygon.
Step 1032: as shown in fig. 4 (b): and (c) judging whether each triangle in the fixed background triangular mesh is positioned inside the clothes outline polygon or not to obtain a set of triangles { T1} positioned inside the clothes outline polygon, wherein the inner triangles are black in the graph in fig. 4(b), and the outer triangles are gray.
The method for judging whether the mesh triangle is positioned in the outline polygon comprises the following steps: firstly, judging whether three vertexes of a triangle are all positioned in the outline polygon or not, and if the three vertexes of the triangle are all positioned in the outline polygon, positioning the triangle in the outline polygon; otherwise, this triangle is outside the outline polygon.
Step 1033: as shown in fig. 4 (c): and connecting the contour line interpolation points with the fixed background triangular grid points to perform edge contour grid triangularization to obtain a triangular set { T2} generated by the contour line interpolation points, and taking a union set of { T1} and { T2} as a triangular set { T } of subsequent simulation and rendering, namely the simulated triangular grid.
The edge contour point triangularization method is shown in fig. 5: a line segment formed by adjacent contour points A and B is L, firstly, a triangle set which is intersected in the L and a fixed background triangular grid is obtained, and the line segment is judged to be whether to be intersected with any one side of the triangle; then connecting the starting point A of the connecting line segment with all the vertexes, which are positioned inside the outline polygon, in the intersecting triangle set to obtain a new triangle {. tangle-solidup ACD }; and finally, connecting the end point B of the line segment L with a grid point D which is connected with the starting point A and has the smallest included angle with the line segment L to obtain a new triangle A. Repeating the steps for all the adjacent contour dotted line segments until all the triangularization is completed.
Step 104: and performing physical simulation on the clothes model on a human body model based on the simulation triangular mesh.
After the clothing simulation triangular mesh is obtained through step 103, trying on the three-dimensional human body model is needed, as shown in fig. 6, the physical simulation specifically includes:
step 1041: as shown in fig. 6(a), a cloth-simulated triangular mesh patch is placed at an initial position with respect to the manikin, and the patch is divided into a front patch and a rear patch corresponding to the front and rear of the manikin, respectively.
Step 1042: as shown in fig. 6(b), a spring-particle model is built according to mesh topology connection of the simulation triangle mesh, wherein the spring comprises: structural, shear, bending and suture springs; the sewing spring is established between the corresponding contour line segments of the surface sheets needing to be sewn.
Step 1043: as shown in fig. 6(c), based on the spring-mass point model, the clothes are simulated on the human body model by a physical method, and the simulation result in the balanced state is obtained.
Step 1044: and performing collision detection and processing on the simulation result of each frame.
Step 105: and editing the clothes in the three-dimensional space based on the physical simulation result to obtain an editing vector.
After the initial simulation of the clothes is completed in step 104, the clothes grid can be directly edited in the three-dimensional space, and the specific process of clothes editing is as follows:
step 1051: firstly, an editing unit needing to be operated is selected through interactive equipment such as a mouse or a keyboard, and the editing unit comprises contour points and contour lines.
Step 1052: editing the selected editing unit in the three-dimensional space to obtain a three-dimensional editing vectorThe editing vector comprises an index of a patch to which an editing unit belongs, a unit index and a three-dimensional space vector
Step 1053: mapping the three-dimensional space editing vector to an editing unit corresponding to the two-dimensional layout space to obtain a two-dimensional editing vector, wherein the mapping method comprises the following steps: as shown in FIG. 7(a), firstly, a local plane rectangular coordinate system XOY is established by using the triangle plane A-ABC where the selected editing unit is located, and then the three-dimensional space editing vector is usedProjecting the image to a local coordinate system to obtain a projection vectorAs shown in fig. 7(b), the vector is projectedMapping to the corresponding editing unit of the two-dimensional layout space to obtain a two-dimensional editing vector
Step 106: updating the clothing model based on the edit vector.
After the clothes are edited in step 105, the two-dimensional version and the three-dimensional patch of the clothes need to be updated simultaneously, and the specific process of the clothes update is as follows:
step 1061: the two-dimensional editing vector obtained in the step 105 is usedAnd the two-dimensional editing unit is applied to the selected two-dimensional editing unit, and the editing unit is divided into contour points and contour lines. The selected editing unit is modified according to the editing vector, and the modification method comprises the following steps: when the editing vector acts on the contour point, the contour point displaces the distance of the modular length of the editing vector in the direction of the editing vector, and then all editing units associated with the contour point are updated; when weavingWhen the edit vector acts on the contour line, the contour line end point, the control point and the interpolation point are displaced by the distance of the modular length of the edit vector in the direction of the edit vector, and then all the edit units associated with the contour line are updated.
Step 1062: and comparing the grids before and after the two-dimensional version updating to obtain a current frame newly added grid point set.
Step 1063: as shown in fig. 8(a), for each newly added grid point p, its local relative position vector on the fixed background triangular grid with respect to the effective point a of the previous frame is calculated in the two-dimensional layout space.
Step 1064: and calculating the initial position p' of the newly added grid point in the three-dimensional space according to the effective point A corresponding to the three-dimensional grid and the relative position vector p, and updating the three-dimensional simulation grid. Step 104 is repeated after the update is complete. As shown in fig. 8(b), the initial position calculation method is: and taking the position obtained by moving the corresponding effective point A by a distance with a small relative position vector modulus in the direction of the relative position vector p as the initial position of the new grid point.
The invention also provides a three-dimensional clothes real-time simulation editing system, which comprises:
and the clothes two-dimensional model outline segment information acquisition module is used for reading and analyzing the clothes two-dimensional model file and acquiring the clothes two-dimensional model outline segment information.
The clothes model building module is used for modeling clothes on a logic and data structure by utilizing a hierarchical structure model based on the two-dimensional model outline segment information of the clothes to obtain a clothes model; the clothes model comprises a two-dimensional model surface patch and a three-dimensional grid; the two-dimensional layout patch comprises a fixed background triangular mesh and a contour, the fixed background triangular mesh comprises mesh points and triangles, and the contour comprises contour points and contour lines;
the simulation triangular network generation module is used for generating a simulation triangular mesh based on the fixed background triangular mesh and the outline;
the physical simulation module is used for carrying out physical simulation on the clothes model on a human body model based on the simulation triangular mesh;
the editing module is used for editing clothes in a three-dimensional space based on a physical simulation result to obtain an editing vector;
an update module to update the clothing model based on the edit vector.
The invention provides a three-dimensional clothes real-time simulation editing method and a three-dimensional clothes real-time simulation editing system aiming at the defects and shortcomings of the existing three-dimensional clothes editing, so that a user can edit clothes in a three-dimensional space in real time and obtain an accurate two-dimensional surface patch type. The method for updating the clothes grid based on the fixed background triangular grid can not only ensure the real-time performance of the simulation speed, but also ensure that the physical simulation parameters of the clothes cannot be changed in the editing process.
The embodiments in the present description are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other. For the system disclosed by the embodiment, the description is relatively simple because the system corresponds to the method disclosed by the embodiment, and the relevant points can be referred to the method part for description.
The principles and embodiments of the present invention have been described herein using specific examples, which are provided only to help understand the method and the core concept of the present invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, the specific embodiments and the application range may be changed. In view of the above, the present disclosure should not be construed as limiting the invention.
Claims (9)
1. A real-time simulation editing method for three-dimensional clothes is characterized by comprising the following steps:
reading and analyzing a clothes two-dimensional model file to obtain the information of a clothes two-dimensional model outline segment;
modeling the clothes on a logic and data structure by utilizing a hierarchical structure model based on the two-dimensional model outline segment information of the clothes to obtain a clothes model; the clothes model comprises a two-dimensional model surface patch and a three-dimensional grid; the two-dimensional layout patch comprises a fixed background triangular mesh and a contour, the fixed background triangular mesh comprises mesh points and triangles, and the contour comprises contour points and contour lines;
generating a simulated triangular mesh based on the fixed background triangular mesh and the contour;
performing physical simulation on the clothes model on a human body model based on the simulation triangular mesh;
editing clothes in a three-dimensional space based on a physical simulation result to obtain an editing vector;
updating the clothing model based on the edit vector.
2. The method for real-time simulation editing of three-dimensional clothes according to claim 1, wherein the two-dimensional layout patches and the three-dimensional mesh have the same topology and index number.
3. The method for real-time simulation editing of three-dimensional clothes according to claim 1, wherein the method for generating the fixed background triangular mesh is as follows:
acquiring a maximum rectangular bounding box of the contour point set;
generating a fixed background grid rectangle based on the maximum rectangle bounding box; the center of the fixed background grid rectangle is the center of the maximum rectangular bounding box, and the length and the width of the fixed background grid rectangle are respectively twice the length and the width of the maximum rectangular bounding box;
uniformly inserting grid points in the inner part of the fixed background grid in the transverse direction and the longitudinal direction at a set grid density;
and carrying out background grid triangulation on the fixed background grid rectangle by taking the inserted grid points as constraint points to obtain a fixed background triangular grid.
4. The method for real-time simulation editing of three-dimensional clothing according to claim 1, wherein the generating of the simulation triangular mesh based on the fixed background triangular mesh and the contour specifically comprises:
determining a clothes outline polygon based on the clothes two-dimensional model outline line segment information;
obtaining triangles in the fixed background triangular mesh positioned inside the clothes outline polygon as a first triangle set
Connecting the interpolation points of the contour lines with the grid points in the fixed background triangular grid to carry out edge contour grid triangularization to obtain a triangular set generated by the interpolation points of the contour lines, wherein the triangular set is a second triangular set;
and taking the union of the first triangle set and the second triangle set as a simulation triangular mesh.
5. The method for real-time simulation editing of three-dimensional clothes according to claim 4, wherein the edge contour mesh triangularization specifically comprises:
acquiring line segments formed by adjacent contour points in the clothes contour polygon;
acquiring a triangle set intersected with the line segment in the fixed background triangular mesh to obtain an intersected triangle set;
connecting the starting point of the line segment with all vertexes, which are positioned inside the clothes outline polygon, in the intersected triangle set to form a first triangle;
connecting the end point of the line segment, the starting point and the grid point with the minimum included angle with the line segment to form a second triangle;
and taking the union of the first triangle and the second triangle as a simulation triangle formed by the line segments.
6. The method for editing three-dimensional clothes in real-time simulation according to claim 1, wherein the physically simulating the clothes model on a human body model based on the simulation triangular mesh specifically comprises:
placing the simulated triangular mesh in an initial position relative to a human body model;
establishing a spring-mass point model according to the mesh topological connection of the simulation triangular mesh;
and performing simulation on the clothes model on the human body model by adopting a physical-based method based on the spring-mass point model.
7. The method for real-time simulation editing of three-dimensional clothes according to claim 1, wherein the editing of clothes in a three-dimensional space based on physical simulation results to obtain an editing vector specifically comprises:
selecting a three-dimensional editing unit needing to be operated in a three-dimensional space based on a simulation result;
editing the selected three-dimensional editing unit in a three-dimensional space to obtain a three-dimensional editing vector;
and mapping the three-dimensional editing vector to an editing unit corresponding to the two-dimensional layout space to obtain a two-dimensional editing vector.
8. The method for real-time simulation editing of three-dimensional clothing according to claim 7, wherein the updating of the clothing model based on the editing vector specifically comprises:
modifying and updating a two-dimensional editing unit in a two-dimensional space according to the two-dimensional editing vector;
updating grids in the two-dimensional layout based on the updated editing unit;
obtaining a current frame newly added grid point set based on the grid in the updated two-dimensional version;
for each newly added grid point, determining an adjacent effective point and a relative position vector;
and calculating the initial position of the newly added grid point in the three-dimensional space according to the adjacent effective point and the relative position vector, and updating the three-dimensional grid.
9. A three-dimensional clothes real-time simulation editing system is characterized by comprising:
and the clothes two-dimensional model outline segment information acquisition module is used for reading and analyzing the clothes two-dimensional model file and acquiring the clothes two-dimensional model outline segment information.
The clothes model building module is used for modeling clothes on a logic and data structure by utilizing a hierarchical structure model based on the two-dimensional model outline segment information of the clothes to obtain a clothes model; the clothes model comprises a two-dimensional model surface patch and a three-dimensional grid; the two-dimensional layout patch comprises a fixed background triangular mesh and a contour, the fixed background triangular mesh comprises mesh points and triangles, and the contour comprises contour points and contour lines;
the simulation triangular network generation module is used for generating a simulation triangular mesh based on the fixed background triangular mesh and the outline;
the physical simulation module is used for carrying out physical simulation on the clothes model on a human body model based on the simulation triangular mesh;
the editing module is used for editing clothes in a three-dimensional space based on a physical simulation result to obtain an editing vector;
an update module to update the clothing model based on the edit vector.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110411454.8A CN113076571B (en) | 2021-04-16 | 2021-04-16 | Real-time simulation editing method and system for three-dimensional clothes |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110411454.8A CN113076571B (en) | 2021-04-16 | 2021-04-16 | Real-time simulation editing method and system for three-dimensional clothes |
Publications (2)
Publication Number | Publication Date |
---|---|
CN113076571A true CN113076571A (en) | 2021-07-06 |
CN113076571B CN113076571B (en) | 2023-11-07 |
Family
ID=76617913
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202110411454.8A Active CN113076571B (en) | 2021-04-16 | 2021-04-16 | Real-time simulation editing method and system for three-dimensional clothes |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN113076571B (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116091679A (en) * | 2023-02-20 | 2023-05-09 | 上海百琪迈科技(集团)有限公司 | Three-dimensional clothing template modeling method and system based on side texture mapping |
Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20040049309A1 (en) * | 2001-01-19 | 2004-03-11 | Gardner James Holden Patrick | Production and visualisation of garments |
CN101826126A (en) * | 2010-04-02 | 2010-09-08 | 浙江大学 | Garment design method based on three-dimensional sketch in any sight |
CN102332180A (en) * | 2011-10-15 | 2012-01-25 | 杭州力孚信息科技有限公司 | Three-dimensional garment modeling and pattern designing method based on draping |
CN104268927A (en) * | 2014-09-12 | 2015-01-07 | 上海明穆电子科技有限公司 | 3D virtual garment automatic generation method and system |
US20150084955A1 (en) * | 2013-09-23 | 2015-03-26 | Beihang University | Method of constructing 3d clothing model based on a single image |
CN105513135A (en) * | 2015-09-15 | 2016-04-20 | 浙江大学 | Spatial position automatic setting method of three-dimensional clothing pattern |
CN107958488A (en) * | 2017-10-16 | 2018-04-24 | 中国科学院自动化研究所 | The interactive editing of clothing cutting plate and sewing method and device |
CN108140250A (en) * | 2015-10-09 | 2018-06-08 | 奥达斯自动化信息产业有限公司 | The Computerized method for the curved surface for representing clothes is created and edited on manikin in virtual three-dimensional environment |
CN108629837A (en) * | 2018-01-09 | 2018-10-09 | 南京大学 | A kind of cloth real-time emulation method for virtual fitting |
-
2021
- 2021-04-16 CN CN202110411454.8A patent/CN113076571B/en active Active
Patent Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20040049309A1 (en) * | 2001-01-19 | 2004-03-11 | Gardner James Holden Patrick | Production and visualisation of garments |
CN101826126A (en) * | 2010-04-02 | 2010-09-08 | 浙江大学 | Garment design method based on three-dimensional sketch in any sight |
CN102332180A (en) * | 2011-10-15 | 2012-01-25 | 杭州力孚信息科技有限公司 | Three-dimensional garment modeling and pattern designing method based on draping |
US20150084955A1 (en) * | 2013-09-23 | 2015-03-26 | Beihang University | Method of constructing 3d clothing model based on a single image |
CN104268927A (en) * | 2014-09-12 | 2015-01-07 | 上海明穆电子科技有限公司 | 3D virtual garment automatic generation method and system |
CN105513135A (en) * | 2015-09-15 | 2016-04-20 | 浙江大学 | Spatial position automatic setting method of three-dimensional clothing pattern |
CN108140250A (en) * | 2015-10-09 | 2018-06-08 | 奥达斯自动化信息产业有限公司 | The Computerized method for the curved surface for representing clothes is created and edited on manikin in virtual three-dimensional environment |
CN107958488A (en) * | 2017-10-16 | 2018-04-24 | 中国科学院自动化研究所 | The interactive editing of clothing cutting plate and sewing method and device |
CN108629837A (en) * | 2018-01-09 | 2018-10-09 | 南京大学 | A kind of cloth real-time emulation method for virtual fitting |
Non-Patent Citations (2)
Title |
---|
H.N. NG等: "Computer graphics techniques for modeling cloth", 《IEEE》, pages 28 - 41 * |
YIPIN YANG等: "Semantic Parametric Reshaping of Human Body Models", 《IEEE》, pages 41 - 48 * |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116091679A (en) * | 2023-02-20 | 2023-05-09 | 上海百琪迈科技(集团)有限公司 | Three-dimensional clothing template modeling method and system based on side texture mapping |
Also Published As
Publication number | Publication date |
---|---|
CN113076571B (en) | 2023-11-07 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
Wang et al. | Design automation for customized apparel products | |
Huang et al. | Block pattern generation: From parameterizing human bodies to fit feature-aligned and flattenable 3D garments | |
Wang et al. | Feature based 3D garment design through 2D sketches | |
Li et al. | Modeling 3D garments by examples | |
JP2013507679A (en) | Method and system capable of 3D printing of 3D object model | |
CN107330962A (en) | A kind of scene generating method and device | |
Yasseen et al. | Sketch-based garment design with quad meshes | |
Ma et al. | B-spline surface local updating with unorganized points | |
Zhang et al. | An integrated method of 3D garment design | |
Wang et al. | From designing products to fabricating them from planar materials | |
US6462740B1 (en) | System for in-scene cloth modification | |
Zhang et al. | A surface based approach to recognition of geometric features for quality freeform surface machining | |
Wang et al. | EQSM: An efficient high quality surface grid generation method based on remeshing | |
CN113076571B (en) | Real-time simulation editing method and system for three-dimensional clothes | |
Wang et al. | Freeform extrusion by sketched input | |
Zell et al. | Elastiface: Matching and blending textured faces | |
CN115690323B (en) | Intelligent clothing push plate method and device | |
CN109940894B (en) | Convolution surface hybrid modeling method based on finite support radius control | |
CN112102470A (en) | Linear microminiaturible parametric clothing model manufacturing method and parameter optimization method thereof | |
Fan et al. | Mesh morphing using polycube‐based cross‐parameterization | |
CN108763767B (en) | VR engine-oriented large-data-volume IGS industrial model POLYGON conversion method | |
Chen et al. | Character animation creation using hand-drawn sketches | |
CN113870406A (en) | Free-form model making and material pasting method and readable storage medium | |
Oh et al. | Generating unified model for dressed virtual humans | |
JP2001109789A (en) | Method and device for creating parts data |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |