Image cross-section simulation method and system, medium and computer

By calculating the intersection relationship between the rectangular frame and the stitching edge and building a transformation matrix, the problem of the inability to preview the cross-page pattern display effect in the prior art is solved, and efficient map position calculation and display are achieved.

CN119442356APending Publication Date: 2025-02-14GUANGZHOU XINJING INFORMATION TECH SERVICE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411097397.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-12
Publication Date
2025-02-14

AI Technical Summary

Technical Problem

Existing clothing simulation technology cannot preview the display effect of patterns at cross-page films in real time, resulting in inefficient design.

Method used

By obtaining flat plates and maps, calculate the intersection relationship between the rectangular frame and the stitching edges, build a transformation matrix, and realize the position calculation and display of the maps on different plates.

Benefits of technology

It achieves the efficiency of quickly determining the location of the map on the clothing, and can preview the display effect of the map on the clothing model in real time, improving design efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119442356A_ABST
    Figure CN119442356A_ABST
Patent Text Reader

Abstract

The invention relates to an image cross-section simulation method and system, a medium and a computer, and by adopting the method, the position of a map on a 3D model can be quickly determined according to the design thought of a designer; according to the method, the position of the map on the second plate can be calculated only by determining the position of the map on the first plate, the display effect of the map on the 3D model is synchronously calculated, and compared with a traditional mode that the map is manually arranged on the 3D model, the efficiency is higher.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of clothing simulation, and more specifically, to an image cross-plate simulation method, system, medium and computer. Background Art

[0002] In the existing technology, virtual clothing simulation technology has entered a rapid development stage in recent years. Most of the mainstream clothing simulation technologies are based on grid-based modeling simulation. When making virtual clothing, designers will place patterns anywhere on the clothing. When the pattern is at the seam between the patterns, it is necessary to first measure the size of the patterns on both sides and set the positions of the patterns on both sides. The process operation is too complicated and cumbersome, the design efficiency is low, and it is impossible to preview the overall display effect of the pattern across the patterns in real time. Summary of the invention

[0003] In view of the deficiencies in the prior art, the purpose of the present invention is to provide an image cross-plate simulation method, system, medium and computer to overcome the shortcoming of the prior art that the cross-plate pattern display effect cannot be previewed in real time.

[0004] The above technical objectives of the present invention are achieved through the following technical solutions: A method for simulating image cross-plates, comprising:

[0005] Acquire a first plane plate, a second plane plate, and a plane map; determine the stitching edges corresponding to the first plane plate and the second plane plate according to a predetermined stitching relationship, record the stitching edge on the first plane plate as a first stitching edge; record the stitching edge on the second plane plate as a second stitching edge; calculate a rectangular frame that can enclose the plane map;

[0006] According to a predetermined clothing design rule, the planar map is placed on a first planar pattern, an intersection relationship between the rectangular frame and the first stitching edge is calculated and recorded as a first intersection relationship, and an area of ​​the planar map located on the first planar pattern is recorded as a first map;

[0007] According to the first intersection relationship, the intersection relationship between the rectangular frame and the second stitching edge is correspondingly determined, which is recorded as a second intersection relationship; according to the first intersection relationship and the second intersection relationship, a transformation matrix is ​​constructed; using the transformation matrix and the first map, the area of ​​the plane map on the second plane plate is calculated, which is recorded as a second map;

[0008] The first plane pattern is transformed into a first space pattern, and according to the transformation relationship, the first map is transformed into a first space map, and the second plane pattern is transformed into a second space pattern, and according to the transformation relationship, the second map is transformed into a second space map; according to a predetermined clothing stitching relationship, the first space pattern and the second space pattern are combined with each other to obtain a three-dimensional clothing model with a map across the stitching line.

[0009] Optionally, before calculating the intersection relationship between the rectangular box and the first stitching edge, it also includes: judging whether there is an intersection relationship between the plane map and the first stitching edge, if so, calculating the intersection relationship between the rectangular box and the first stitching edge, if not, directly converting the first plane pattern into the first space pattern according to predetermined clothing design rules, and combining it with other space patterns to obtain a three-dimensional clothing model with a map.

[0010] Optionally, the calculation of the intersection relationship between the rectangular box and the first stitching edge, recorded as the first intersection relationship, includes: using a curve intersection algorithm to calculate two intersection points of the rectangular box and the first stitching edge, recorded as a first starting point and a first end point, respectively; recording the two endpoints of the first stitching edge as a first endpoint and a second endpoint, respectively; obtaining the length between the first endpoint and the second endpoint, recorded as a first length; obtaining the length between the first starting point and the first endpoint, recorded as a second length, obtaining the length between the first end point and the second endpoint, recorded as a third length; calculating the ratio of the second length to the first length to obtain a first ratio, calculating the ratio of the third length to the first length to obtain a second ratio, and recording the first ratio and the second ratio as a first intersection relationship.

[0011] Optionally, the intersection relationship between the rectangular box and the second stitching edge is determined according to the first intersection relationship, which is recorded as a second intersection relationship, including: recording the two endpoints of the second stitching edge as the third endpoint and the fourth endpoint respectively; obtaining the length between the third endpoint and the fourth endpoint, which is recorded as the fourth length; determining the positions of the two intersection points of the rectangular box and the second stitching edge on the second stitching edge according to the first ratio, the second ratio and the fourth length, which are recorded as the second starting point and the second end point respectively; marking the coordinates of the second starting point and the coordinates of the second end point as the second intersection relationship.

[0012] Optionally, constructing a transformation matrix based on the first intersection relationship and the second intersection relationship includes: obtaining a vector pointing from the first starting point to the first end point, recorded as a first vector, obtaining a vector pointing from the second starting point to the second end point, recorded as a second vector; obtaining a vector pointing from the first starting point to the second starting point, recorded as a third vector; and using the first vector, the second vector and the third vector to construct a transformation matrix.

[0013] Optionally, the method of transforming the first plane plate into the first spatial plate, transforming the first map into the first spatial map according to the transformation relationship, transforming the second plane plate into the second spatial plate, and transforming the second map into the second spatial map according to the transformation relationship includes: generating a first plane triangular mesh on the first plane plate, generating a second plane triangular mesh on the second plane plate, obtaining a first correspondence between the first map and the vertices on the first plane triangular mesh, and a second correspondence between the second map and the vertices on the second plane triangular mesh; transforming the first plane plate into the first spatial plate according to a predetermined rule to obtain the first spatial triangular mesh, and transforming the second plane plate into the second spatial plate to obtain the second spatial triangular mesh; transforming the first map into the first spatial map according to the transformation relationship and the first correspondence between the first plane triangular mesh and the first spatial triangular mesh; and transforming the second map into the second spatial map according to the transformation relationship and the second correspondence between the second plane triangular mesh and the second spatial triangular mesh.

[0014] Optionally, it also includes: determining whether one of the endpoints of the first stitching edge is located inside the rectangular frame; if so, recording the intersection of the first stitching edge and the rectangular frame as the first starting point, and recording the endpoint of the first stitching edge located inside the rectangular frame as the first end point; correspondingly, recording the intersection of the rectangular frame and the second stitching edge as the second starting point, and recording the endpoint of the second stitching edge located inside the rectangular frame as the second end point.

[0015] An image cross-plate simulation system, comprising:

[0016] Plane plate acquisition module: used to acquire a first plane plate, a second plane plate and a plane map; determine the stitching edges corresponding to the first plane plate and the second plane plate according to a predetermined stitching relationship, record the stitching edge on the first plane plate as a first stitching edge; and record the stitching edge on the second plane plate as a second stitching edge;

[0017] Rectangular frame calculation module: used to calculate a rectangular frame that can surround the plane map;

[0018] A first intersection relationship calculation module: used for placing the plane map on the first plane plate according to a predetermined clothing design rule, calculating the intersection relationship between the rectangular frame and the first stitching edge, recorded as a first intersection relationship, and recording the area of ​​the plane map located on the first plane plate as a first map;

[0019] A second mapping calculation module: used to determine the intersection relationship between the rectangular frame and the second stitching edge according to the first intersection relationship, recorded as a second intersection relationship; construct a transformation matrix according to the first intersection relationship and the second intersection relationship; and calculate the area of ​​the plane mapping on the second plane plate by using the transformation matrix and the first mapping, recorded as a second mapping;

[0020] Three-dimensional clothing model generation module: used to transform the first plane pattern into the first space pattern, transform the first map into the first space map according to the transformation relationship, transform the second plane pattern into the second space pattern, and transform the second map into the second space map according to the transformation relationship; according to the predetermined clothing stitching relationship, combine the first space pattern and the second space pattern to obtain a three-dimensional clothing model with a map across the stitching line.

[0021] A computer-readable storage medium stores a computer program, which implements the steps of the above method when executed by a processor.

[0022] A computer device comprises a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of the above method when executing the computer program.

[0023] In summary, the present invention has the following beneficial effects: the clothing model obtained by the present method can quickly determine the position of the sticker on the clothing according to the actual clothing design idea. It only needs to determine the position of the sticker on the first plate to calculate the position of the sticker on the second plate, and simultaneously calculate the display effect of the sticker on the clothing model. Compared with the traditional manual setting of the sticker on the clothing model, it has higher efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0024] Figure 1 A flow chart of an image cross-plate simulation method of the present invention;

[0025] Figure 2 A structural diagram of an image cross-plate simulation system of the present invention;

[0026] Figure 3 is an internal structure diagram of a computer device in an embodiment of the present invention;

[0027] Figure 4 It is a schematic diagram of the present invention in which the sticker does not cross the stitching edge of the plate;

[0028] Figure 5 A schematic diagram of a sticker of the present invention crossing over the stitching edges of two panels;

[0029] Figure 6 A schematic diagram of stitching edges of a plurality of panels according to the present invention;

[0030] Figure 7 It is a schematic diagram of rendering of a three-dimensional clothing model of the present invention.

[0031] In the figure: 1. Plane pattern acquisition module; 2. Rectangular frame calculation module; 3. First intersection relationship calculation module; 4. Second mapping calculation module; 5. Three-dimensional clothing model generation module. DETAILED DESCRIPTION

[0032] In order to make the purpose, features and advantages of the present invention more obvious and easy to understand, the specific implementation methods of the present invention are described in detail below in conjunction with the accompanying drawings. Several embodiments of the present invention are shown in the accompanying drawings. However, the present invention can be implemented in many different forms and is not limited to the embodiments described herein.

[0033] In the present invention, unless otherwise clearly specified and limited, the terms "installed", "connected", "connected", "fixed" and the like should be understood in a broad sense. For example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be indirectly connected through an intermediate medium, or it can be the internal connection of two elements. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to the specific circumstances. The terms "first" and "second" are used for descriptive purposes only and cannot be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include one or more of the features.

[0034] In the present invention, unless otherwise clearly specified and limited, the first feature being "above" or "below" the second feature may include the first and second features being in direct contact, or may include the first and second features being in contact not directly but through another feature between them. Moreover, the first feature being "above", "above" and "above" the second feature includes the first feature being directly above and obliquely above the second feature, or simply indicates that the first feature is higher in level than the second feature. The first feature being "below", "below" and "below" the second feature includes the first feature being directly below and obliquely below the second feature, or simply indicates that the first feature is lower in level than the second feature. The terms "vertical", "horizontal", "left", "right", "above", "below" and similar expressions are for illustrative purposes only, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as limiting the present invention.

[0035] The present invention is described in detail below in conjunction with the accompanying drawings and embodiments.

[0036] The present invention provides an image cross-plate simulation method, such as Figure 1As shown, including:

[0037] S01, obtaining a first plane plate, a second plane plate and a plane map; determining the stitching edges corresponding to the first plane plate and the second plane plate according to a predetermined stitching relationship, recording the stitching edge located on the first plane plate as a first stitching edge; recording the stitching edge located on the second plane plate as a second stitching edge; calculating a rectangular frame that can enclose the plane map;

[0038] S02, according to a predetermined clothing design rule, placing the plane map on a first plane plate, calculating the intersection relationship between the rectangular frame and the first stitching edge, recording it as a first intersection relationship, and recording the area of ​​the plane map located on the first plane plate as a first map;

[0039] S03, according to the first intersection relationship, correspondingly determining the intersection relationship between the rectangular frame and the second stitching edge, recorded as a second intersection relationship; according to the first intersection relationship and the second intersection relationship, constructing a transformation matrix; using the transformation matrix and the first map, calculating the area of ​​the plane map on the second plane plate, recorded as a second map;

[0040] S04, transforming the first plane pattern into a first space pattern, transforming the first map into a first space map according to the transformation relationship, transforming the second plane pattern into a second space pattern, and transforming the second map into a second space map according to the transformation relationship; combining the first space pattern and the second space pattern according to a predetermined clothing stitching relationship to obtain a three-dimensional clothing model with a map across the stitching line.

[0041] In practical applications, in order to make the flat map meet the actual clothing design needs, it is necessary to put the flat map on the clothing pattern according to the actual clothing design. In actual situations, there are mainly three situations: 1. The map does not cross the seam line between the patterns (such as Figure 4 2. The texture crosses the seam line between two patterns (as shown in Figure 5 3. The texture crosses the seam lines of multiple tiles (as shown in Figure 6 As shown). The first case does not require the use of the cross-plate simulation method of the present application, so it will not be described in detail in the present application. The third case can be regarded as a further case of the second case, that is, the third case can be divided into two steps. First, the texture spans two plates, and then the two textures spanning the two plates are respectively vertically spanned across two adjacent plates to achieve multi-plate spanning of the texture. Therefore, in the present application, only the second case is described. It is known to those skilled in the art that the situation where the texture spans multiple plates can be obtained through multiple adjustments.

[0042] In order to obtain a three-dimensional clothing model with a map, it is first necessary to obtain the corresponding clothing plane pattern according to the design of the clothing. According to the above description, this application only describes the situation where the map crosses two patterns. Two patterns usually have only one common stitching edge. In order to determine the specific position of the plane map, it is necessary to calculate the rectangular frame that can surround the plane map. By calculating the intersection between the rectangular frame and the stitching edge, the relative position of the rectangular frame and the plane map can be determined. The first step is to place the plane map on the first plane pattern and determine the relative position between the rectangular frame and the first plane pattern. Since the plane map is across patterns, the plane map will cross the first stitching edge of the first plane pattern, that is, there will be two corresponding intersections between the rectangular frame and the first stitching edge. Since there is a corresponding relationship between the second stitched edge and the first stitched edge (the corresponding relationship is not necessarily equal in length, but can also be extended in a certain ratio. For example, if a wavy plate is stitched on the edge of a straight plate, then there will be a length ratio relationship between the wavy plate edge and the straight edge), it is necessary to calculate the intersection relationship between the rectangular frame and the second stitched edge based on the first intersection relationship and the predetermined stitching ratio, that is, to determine the positions of the two intersection points of the rectangular frame and the second stitched edge on the second stitched edge according to the ratio. After determining the two intersection points, the area of ​​the rectangular frame on the second plane plate can be determined based on the magnification (reduction) ratio, the rotation angle, and the translation distance. Then, the first plane plate and the second plane plate are respectively transformed into spatial plane plates, and the plane stickers on the plane plates are also transformed. Figure 1 By the same transformation, a clothing model with a three-dimensional map can be obtained.

[0043] In summary, the clothing model obtained by this method can quickly determine the position of the texture on the clothing according to the actual clothing design ideas. It only needs to determine the position of the texture on the first plate to calculate the position of the texture on the second plate, and simultaneously calculate the display effect of the texture on the clothing model. Compared with the traditional manual setting of the texture on the clothing model, it has higher efficiency.

[0044] Furthermore, before calculating the intersection relationship between the rectangular frame and the first stitching edge, it also includes: judging whether there is an intersection relationship between the plane map and the first stitching edge, if so, calculating the intersection relationship between the rectangular frame and the first stitching edge, if not, directly converting the first plane pattern into the first space pattern according to the predetermined clothing design rules, and combining it with other space patterns to obtain a three-dimensional clothing model with a map.

[0045] In practical applications, it is necessary to first determine whether the texture crosses the edge of the template. If it does not cross the edge of the template, there is no need to go through the subsequent planar texture calculation process. You only need to put the planar texture on the first planar template and then transform it into the first spatial template following the first planar template.

[0046] Furthermore, the calculating of the intersection relationship between the rectangular frame and the first stitching edge, recorded as a first intersection relationship, includes:

[0047] Using a curve intersection algorithm, two intersection points of the rectangular frame and the first stitching edge are calculated, and are recorded as a first starting point and a first end point respectively; and two end points of the first stitching edge are recorded as a first end point and a second end point respectively;

[0048] Obtain the length between the first endpoint and the second endpoint, recorded as the first length L1; obtain the length between the first starting point and the first endpoint, recorded as the second length L2, obtain the length between the first end point and the second endpoint, recorded as the third length L3;

[0049] The ratio of the second length L2 to the first length L1 is calculated to obtain a first ratio L2 / L1, and the ratio of the third length to the first length is calculated to obtain a second ratio L3 / L1. The first ratio L2 / L1 and the second ratio L3 / L1 are recorded as a first intersection relationship.

[0050] In practical applications, the curve intersection algorithm usually refers to the simultaneous equations to calculate the intersection of the curves. Specifically, the following calculation process can be used: 1) Use the AABB model (Ai xe Al i gn Bound i ng Box) to construct the bounding box of each curve, and perform interference judgment on the constructed bounding box. If there is spatial interference, proceed to the next step, otherwise exit this judgment; 2) Divide the curves in the interference space into two segments, that is, divide them into 2 segments, and the 2 curves into four segments. For two-by-two detections, execute step 1); 3) Exit condition: the curve segment is less than a certain threshold or reaches other detection accuracy. Since the length between the first stitching edge and the second stitching edge is not necessarily equal, but there may be a certain length ratio, in order to ensure the uniformity of the plane mapping, it is necessary to calculate the relative position of the rectangular box on the first stitching edge, which is the first intersection relationship mentioned in this application.

[0051] Furthermore, the determining of the intersection relationship between the rectangular frame and the second stitching edge according to the first intersection relationship, recorded as a second intersection relationship, includes:

[0052] Recording the two endpoints of the second stitching edge as the third endpoint and the fourth endpoint respectively;

[0053] Obtain the length between the third endpoint and the fourth endpoint, recorded as the fourth length L4;

[0054] According to the first ratio, the second ratio and the fourth length, on the second stitching edge, the positions of the two intersection points of the rectangular frame and the second stitching edge are determined and recorded as the second starting point and the second end point respectively; the coordinates of the second starting point and the coordinates of the second end point are marked as a second intersection relationship.

[0055] In practical applications, since the positions between the rectangular frame and the first stitching edge, and the positions between the rectangular frame and the second stitching edge are relatively fixed, the ratio of the first starting point to the first end point, that is, the first ratio L2 / L1 and the fourth length L4, can be used to determine the position of the second starting point on the second stitching edge, that is, to determine the distance from the second starting point to the third end point: L5=L4*L2 / L1. Similarly, the second ratio L3 / L1 and the fourth length L4 are used to determine the position of the second end point on the second stitching edge, that is, to determine the distance from the second end point to the fourth end point: L6=L4*L3 / L1. Then, the distance between the second starting point and the second end point is used to redetermine the size of the planar map located on the second planar plate. Since the stitching edge can be approximately regarded as a line without width, the first starting point and the second starting point can be regarded as the same point. Similarly, the first end point and the second end point can be regarded as the same point. Then, by determining the positions of two points on the rectangular frame, the position, angle and size of the rectangular frame are determined, and the area of ​​the planar map on the second planar plate can be determined.

[0056] Furthermore, constructing a transformation matrix according to the first intersection relationship and the second intersection relationship includes:

[0057] Obtain a vector pointing from the first starting point to the first end point, recorded as the first vector, obtain a vector pointing from the second starting point to the second end point, recorded as the second vector; obtain a vector pointing from the first starting point to the second starting point, recorded as the third vector; use the first vector, the second vector and the third vector to construct a transformation matrix.

[0058] In practical applications, those skilled in the art will know that since matrix multiplication does not have a commutative law, different matrices are used for translation, transformation, and scaling of a planar map in different orders. By constructing a transformation matrix in a predetermined order, the transformation of a planar map from a first planar map to a second planar map can be achieved.

[0059] Further, the first plane plate is transformed into the first space plate, the first map is transformed into the first space map according to the transformation relationship, the second plane plate is transformed into the second space plate, and the second map is transformed into the second space map according to the transformation relationship, including:

[0060] Generate a first planar triangular mesh on the first planar plate, generate a second planar triangular mesh on the second planar plate, obtain a first correspondence between the first map and the vertices on the first planar triangular mesh, and obtain a second correspondence between the second map and the vertices on the second planar triangular mesh;

[0061] According to a predetermined rule, the first plane plate is transformed into a first space plate, and a first space triangular mesh is obtained accordingly; the second plane plate is transformed into a second space plate, and a second space triangular mesh is obtained accordingly;

[0062] According to a transformation relationship and a first correspondence relationship between the first plane triangular mesh and the first space triangular mesh, the first texture is converted into a first space texture;

[0063] The second map is converted into a second space map according to the transformation relationship between the second plane triangular mesh and the second space triangular mesh and the second corresponding relationship.

[0064] In practical applications, by meshing the plane plate and corresponding the plane map with the triangular mesh, the plane map can be transformed into a spatial graphic along with the plane plate during the actual transformation process, so that the plane map can be transformed into a three-dimensional map on the three-dimensional plate along with the plane plate.

[0065] Furthermore, it also includes: determining whether one of the endpoints of the first stitching edge is located inside the rectangular frame; if so, recording the intersection of the first stitching edge and the rectangular frame as the first starting point, and recording the endpoint of the first stitching edge located inside the rectangular frame as the first end point; correspondingly, recording the intersection of the rectangular frame and the second stitching edge as the second starting point, and recording the endpoint of the second stitching edge located inside the rectangular frame as the second end point.

[0066] In practical applications, such as Figure 6 As shown, if one endpoint of the first stitching edge is located inside the rectangular frame, that is, the stitching edge does not completely divide the plane map into two parts, then the endpoint can be used as the first end point of the rectangular frame to divide the plane map, and then the two first edges connected end to end can be used to complete the division of the plane map.

[0067] like Figure 2 As shown, the present invention also provides an image cross-plate simulation system, comprising:

[0068] Plane plate acquisition module: used to acquire a first plane plate, a second plane plate and a plane map; determine the stitching edges corresponding to the first plane plate and the second plane plate according to a predetermined stitching relationship, record the stitching edge on the first plane plate as a first stitching edge; and record the stitching edge on the second plane plate as a second stitching edge;

[0069] Rectangular frame calculation module: used to calculate a rectangular frame that can surround the plane map;

[0070] A first intersection relationship calculation module: used for placing the plane map on the first plane plate according to a predetermined clothing design rule, calculating the intersection relationship between the rectangular frame and the first stitching edge, recorded as a first intersection relationship, and recording the area of ​​the plane map located on the first plane plate as a first map;

[0071] A second mapping calculation module: used to determine the intersection relationship between the rectangular frame and the second stitching edge according to the first intersection relationship, recorded as a second intersection relationship; construct a transformation matrix according to the first intersection relationship and the second intersection relationship; and calculate the area of ​​the plane mapping on the second plane plate by using the transformation matrix and the first mapping, recorded as a second mapping;

[0072] Three-dimensional clothing model generation module: used to transform the first plane pattern into the first space pattern, transform the first map into the first space map according to the transformation relationship, transform the second plane pattern into the second space pattern, and transform the second map into the second space map according to the transformation relationship; according to the predetermined clothing stitching relationship, combine the first space pattern and the second space pattern to obtain a three-dimensional clothing model with a map across the stitching line.

[0073] The specific definition of an image cross-plate simulation system can be found in the definition of an image cross-plate simulation method mentioned above, which will not be repeated here. Each module in the above-mentioned image cross-plate simulation system can be implemented in whole or in part by software, hardware and a combination thereof. The above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.

[0074] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as follows: Figure 3 As shown. The computer device includes a processor, a memory, a network interface and a database connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. When the computer program is executed by the processor, an image cross-plate simulation method is implemented.

[0075] Those skilled in the art will understand that Figure 3The 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.

[0076] In one embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the computer program, the following steps are implemented:

[0077] Acquire a first plane plate, a second plane plate, and a plane map; determine the stitching edges corresponding to the first plane plate and the second plane plate according to a predetermined stitching relationship, record the stitching edge on the first plane plate as a first stitching edge; record the stitching edge on the second plane plate as a second stitching edge; calculate a rectangular frame that can enclose the plane map;

[0078] According to a predetermined clothing design rule, the planar map is placed on a first planar pattern, an intersection relationship between the rectangular frame and the first stitching edge is calculated and recorded as a first intersection relationship, and an area of ​​the planar map located on the first planar pattern is recorded as a first map;

[0079] According to the first intersection relationship, the intersection relationship between the rectangular frame and the second stitching edge is correspondingly determined, which is recorded as a second intersection relationship; according to the first intersection relationship and the second intersection relationship, a transformation matrix is ​​constructed; using the transformation matrix and the first map, the area of ​​the plane map on the second plane plate is calculated, which is recorded as a second map;

[0080] The first plane pattern is transformed into a first space pattern, and according to the transformation relationship, the first map is transformed into a first space map, and the second plane pattern is transformed into a second space pattern, and according to the transformation relationship, the second map is transformed into a second space map; according to a predetermined clothing stitching relationship, the first space pattern and the second space pattern are combined with each other to obtain a three-dimensional clothing model with a map across the stitching line.

[0081] In one embodiment, before calculating the intersection relationship between the rectangular frame and the first stitching edge, it also includes: judging whether there is an intersection relationship between the plane map and the first stitching edge, if so, calculating the intersection relationship between the rectangular frame and the first stitching edge, if not, directly converting the first plane pattern into a first space pattern according to predetermined clothing design rules, and combining it with other space patterns to obtain a three-dimensional clothing model with a map.

[0082] In one embodiment, the calculation of the intersection relationship between the rectangular box and the first stitching edge, recorded as the first intersection relationship, includes: using a curve intersection algorithm to calculate two intersection points between the rectangular box and the first stitching edge, recorded as a first starting point and a first end point respectively; recording the two endpoints of the first stitching edge as a first endpoint and a second endpoint respectively; obtaining the length between the first endpoint and the second endpoint, recorded as a first length; obtaining the length between the first starting point and the first endpoint, recorded as a second length, obtaining the length between the first end point and the second endpoint, recorded as a third length; calculating the ratio of the second length to the first length to obtain a first ratio, calculating the ratio of the third length to the first length to obtain a second ratio, and recording the first ratio and the second ratio as a first intersection relationship.

[0083] In one embodiment, the intersection relationship between the rectangular box and the second stitching edge is determined according to the first intersection relationship, which is recorded as the second intersection relationship, including: recording the two endpoints of the second stitching edge as the third endpoint and the fourth endpoint respectively; obtaining the length between the third endpoint and the fourth endpoint, which is recorded as the fourth length; according to the first ratio, the second ratio and the fourth length, on the second stitching edge, determining the positions of the two intersection points of the rectangular box and the second stitching edge, which are recorded as the second starting point and the second end point respectively; marking the coordinates of the second starting point and the coordinates of the second end point as the second intersection relationship.

[0084] In one embodiment, constructing a transformation matrix based on the first intersection relationship and the second intersection relationship includes: obtaining a vector pointing from the first starting point to the first end point, recorded as a first vector, obtaining a vector pointing from the second starting point to the second end point, recorded as a second vector; obtaining a vector pointing from the first starting point to the second starting point, recorded as a third vector; and using the first vector, the second vector and the third vector to construct a transformation matrix.

[0085] In one embodiment, the first planar plate is transformed into the first spatial plate, the first texture is transformed into the first spatial texture according to the transformation relationship, the second planar plate is transformed into the second spatial plate, and the second texture is transformed into the second spatial texture according to the transformation relationship, including:

[0086] Generate a first planar triangular mesh on the first planar plate, generate a second planar triangular mesh on the second planar plate, obtain a first correspondence between the first map and the vertices on the first planar triangular mesh, and obtain a second correspondence between the second map and the vertices on the second planar triangular mesh;

[0087] According to a predetermined rule, the first plane plate is transformed into a first space plate, and a first space triangular mesh is obtained accordingly; the second plane plate is transformed into a second space plate, and a second space triangular mesh is obtained accordingly;

[0088] According to a transformation relationship and a first correspondence relationship between the first plane triangular mesh and the first space triangular mesh, the first texture is converted into a first space texture;

[0089] The second map is converted into a second space map according to the transformation relationship between the second plane triangular mesh and the second space triangular mesh and the second corresponding relationship.

[0090] In one embodiment, it also includes: determining whether one of the endpoints of the first stitching edge is located inside the rectangular frame, and if so, recording the intersection of the first stitching edge and the rectangular frame as the first starting point, and recording the endpoint of the first stitching edge located inside the rectangular frame as the first end point, and correspondingly, recording the intersection of the rectangular frame and the second stitching edge as the second starting point, and recording the endpoint of the second stitching edge located inside the rectangular frame as the second end point.

[0091] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing related hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct RAMbus dynamic RAM (DRDRAM), and RAMbus dynamic RAM (RDRAM), etc.

[0092] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0093] The above is only a preferred embodiment of the present invention, and the protection scope of the present invention is not limited to the above embodiments. All technical solutions under the concept of the present invention belong to the protection scope of the present invention. It should be pointed out that for ordinary technicians in this technical field, some improvements and modifications without departing from the principle of the present invention should also be regarded as the protection scope of the present invention.

Claims

1. An image cross-plate simulation method, characterized in that: include: Acquire a first plane plate, a second plane plate, and a plane map; determine the stitching edge corresponding to the first plane plate and the second plane plate according to a predetermined stitching relationship, and record the stitching edge on the first plane plate as a first stitching edge; Recording the stitching edge on the second planar plate as the second stitching edge; Calculate a rectangular box that can enclose the planar map; According to a predetermined clothing design rule, the planar map is placed on a first planar pattern, an intersection relationship between the rectangular frame and the first stitching edge is calculated and recorded as a first intersection relationship, and an area of ​​the planar map located on the first planar pattern is recorded as a first map; According to the first intersection relationship, the intersection relationship between the rectangular frame and the second stitching edge is correspondingly determined, which is recorded as a second intersection relationship; Constructing a transformation matrix according to the first intersection relationship and the second intersection relationship; Using the transformation matrix and the first map, calculate the area of ​​the planar map on the second planar plate, recorded as the second map; The first plane pattern is transformed into a first space pattern, and according to the transformation relationship, the first map is transformed into a first space map, and the second plane pattern is transformed into a second space pattern, and according to the transformation relationship, the second map is transformed into a second space map; according to a predetermined clothing stitching relationship, the first space pattern and the second space pattern are combined with each other to obtain a three-dimensional clothing model with a map across the stitching line.

2. The image cross-plate simulation method according to claim 1, characterized in that: Before calculating the intersection relationship between the rectangular frame and the first stitching edge, it also includes: judging whether there is an intersection relationship between the plane map and the first stitching edge, if so, calculating the intersection relationship between the rectangular frame and the first stitching edge, if not, directly converting the first plane pattern into a first space pattern according to predetermined clothing design rules, and combining it with other space patterns to obtain a three-dimensional clothing model with a map.

3. The image cross-plate simulation method according to claim 1, characterized in that: The calculating the intersection relationship between the rectangular frame and the first stitching edge, recorded as a first intersection relationship, includes: Using a curve intersection algorithm, two intersection points of the rectangular frame and the first stitching edge are calculated, and are recorded as a first starting point and a first end point respectively; and two end points of the first stitching edge are recorded as a first end point and a second end point respectively; Obtain the length between the first endpoint and the second endpoint, recorded as the first length; obtain the length between the first starting point and the first endpoint, recorded as the second length, obtain the length between the first end point and the second endpoint, recorded as the third length; The ratio of the second length to the first length is calculated to obtain a first ratio, the ratio of the third length to the first length is calculated to obtain a second ratio, and the first ratio and the second ratio are recorded as a first intersection relationship.

4. The image cross-plate simulation method according to claim 3, characterized in that: The step of determining the intersection relationship between the rectangular frame and the second stitching edge according to the first intersection relationship, recorded as a second intersection relationship, includes: Recording the two endpoints of the second stitching edge as the third endpoint and the fourth endpoint respectively; Get the length between the third endpoint and the fourth endpoint, recorded as the fourth length; According to the first ratio, the second ratio and the fourth length, on the second stitching edge, the positions of the two intersection points of the rectangular frame and the second stitching edge are determined and recorded as the second starting point and the second end point respectively; the coordinates of the second starting point and the coordinates of the second end point are marked as a second intersection relationship.

5. The image cross-plate simulation method according to claim 4, characterized in that: The step of constructing a transformation matrix according to the first intersection relationship and the second intersection relationship includes: Obtain a vector pointing from the first starting point to the first end point, recorded as the first vector, obtain a vector pointing from the second starting point to the second end point, recorded as the second vector; obtain a vector pointing from the first starting point to the second starting point, recorded as the third vector; use the first vector, the second vector and the third vector to construct a transformation matrix.

6. The image cross-plate simulation method according to claim 1, characterized in that: The step of transforming the first plane plate into the first space plate, transforming the first map into the first space map according to the transformation relationship, transforming the second plane plate into the second space plate, and transforming the second map into the second space map according to the transformation relationship includes: Generate a first planar triangular mesh on the first planar plate, generate a second planar triangular mesh on the second planar plate, obtain a first correspondence between the first map and the vertices on the first planar triangular mesh, and obtain a second correspondence between the second map and the vertices on the second planar triangular mesh; According to a predetermined rule, the first plane plate is transformed into a first space plate, and a first space triangular mesh is obtained accordingly; the second plane plate is transformed into a second space plate, and a second space triangular mesh is obtained accordingly; According to a transformation relationship and a first correspondence relationship between the first plane triangular mesh and the first space triangular mesh, the first texture is converted into a first space texture; The second map is converted into a second space map according to the transformation relationship between the second plane triangular mesh and the second space triangular mesh and the second corresponding relationship.

7. The image cross-plate simulation method according to claim 1, characterized in that: Also includes: Determine whether one of the endpoints of the first stitching edge is located inside the rectangular frame. If so, record the intersection of the first stitching edge and the rectangular frame as the first starting point, and record the endpoint of the first stitching edge located inside the rectangular frame as the first end point. Correspondingly, record the intersection of the rectangular frame and the second stitching edge as the second starting point, and record the endpoint of the second stitching edge located inside the rectangular frame as the second end point.

8. An image cross-plate simulation system, characterized in that: include: Plane pattern acquisition module: used to acquire the first plane pattern, the second plane pattern and the plane map; According to a predetermined stitching relationship, determining stitching edges corresponding to the first planar plate and the second planar plate, and recording the stitching edge on the first planar plate as a first stitching edge; Recording the stitching edge on the second planar plate as the second stitching edge; Rectangular frame calculation module: used to calculate a rectangular frame that can surround the plane map; A first intersection relationship calculation module: used for placing the plane map on the first plane plate according to a predetermined clothing design rule, calculating the intersection relationship between the rectangular frame and the first stitching edge, recorded as a first intersection relationship, and recording the area of ​​the plane map located on the first plane plate as a first map; A second mapping calculation module: used for determining the intersection relationship between the rectangular frame and the second stitching edge according to the first intersection relationship, which is recorded as a second intersection relationship; Constructing a transformation matrix according to the first intersection relationship and the second intersection relationship; Using the transformation matrix and the first map, calculate the area of ​​the planar map on the second planar plate, recorded as the second map; Three-dimensional clothing model generation module: used to transform the first plane pattern into the first space pattern, transform the first map into the first space map according to the transformation relationship, transform the second plane pattern into the second space pattern, and transform the second map into the second space map according to the transformation relationship; according to the predetermined clothing stitching relationship, combine the first space pattern and the second space pattern to obtain a three-dimensional clothing model with a map across the stitching line.

9. 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 7 are implemented.

10. 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 7 are implemented.