Parallel contour line branch processing method and device based on Voronoi diagram

Through the parallel contour branch processing method based on Voronoi diagram, the problem of large calculation amount and complexity of contour branch problem in 3D modeling is solved, efficient and accurate decomposition and connection are achieved, and the quality of 3D surface reconstruction is improved.

CN113554758BActive Publication Date: 2024-08-23NANJING NORMAL UNIVERSITY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110823732.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-07-21
Publication Date
2024-08-23
Estimated Expiration
2041-07-21

AI Technical Summary

Technical Problem

When the existing technology handles the contour branch problem in 3D modeling, the calculation amount is large and the algorithm is complex. It is difficult to achieve efficient and accurate decomposition or connection position calculation, which affects the quality of 3D surface reconstruction.

Method used

The parallel contour line branch processing method based on the Voronoi diagram is used to project the branch contours through coordinate transformation, generate the Voronoi diagram and extract the dividing lines, and combine the matching method to complete the contour line correspondence to achieve efficient and accurate separation and connection.

Benefits of technology

It improves the accuracy and automation of contour branch processing, reduces the amount of calculation, is suitable for practical applications, and ensures the quality of three-dimensional surface reconstruction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113554758B
    Figure CN113554758B
Patent Text Reader

Abstract

The present invention discloses a parallel contour line branch processing method and device based on Voronoi diagram, the method comprising: (1) obtaining a contour line P to be segmented and a branch contour line set S; (2) projecting the branch contour line set S to the plane where the contour line P is located by coordinate transformation, and obtaining the projected branch contour line set S'; (3) obtaining all contour line fixed points from the projected branch contour line set S', generating a plane point set PP, and creating a contour line Voronoi diagram; (4) extracting segmentation lines based on the Voronoi diagram, and storing them in a segmentation line set SL; (5) separating the contour line P to be segmented based on the segmentation line set SL, obtaining segmentation contour lines, and storing them in a segmentation contour line set L; (6) using a matching method to complete contour line correspondence based on the projected branch contour line set S' and the segmentation contour line set L. The present invention has high accuracy and small calculation amount.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the fields of three-dimensional modeling and graphics, and in particular to a parallel contour line branch processing method and device based on a Voronoi diagram. Background Art

[0002] Using a series of contour lines of an object to reconstruct the surface of a three-dimensional body is an important three-dimensional modeling method, which has been widely used in medical CT slice imaging, three-dimensional geological modeling, terrain surface reconstruction and other fields. In the process of three-dimensional surface reconstruction based on contour lines, when the contour line on a section corresponds to multiple contour lines on adjacent layers, a branching problem will occur. The reasonable solution to the branching problem is the key to ensuring the modeling quality of the branching part. At present, the methods to solve the branching problem mainly include the decomposition and combination contour line method (Shinagawa and Kunnii, 1991), the intermediate layer contour line interpolation method (Ekoule et al., 1991) and the central axis insertion method (Oliva et al., 1996). The intermediate layer contour line interpolation method and the central axis insertion method are not suitable for practical applications due to their large amount of calculation and complex algorithms; the decomposition and combination contour line method is widely used due to its relatively simple algorithm. However, the choice of decomposition or connection position in this method is crucial. How to accurately calculate the decomposition or connection position based on the existing contour line data is the key to affecting the subsequent contour line correspondence processing and the quality of three-dimensional surface reconstruction. Summary of the invention

[0003] Purpose of the invention: In view of the problems existing in the prior art, the present invention provides a method and device for processing parallel contour line branches based on the Voronoi diagram with high accuracy and low calculation amount.

[0004] Technical solution: The parallel contour line branch processing method based on the Voronoi diagram of the present invention comprises:

[0005] (1) Obtain the contour line P to be segmented and the branch contour line set S;

[0006] (2) Projecting the branch contour line set S onto the plane where the contour line P is located through coordinate transformation to obtain the projected branch contour line set S';

[0007] (3) Obtain all contour fixed points from the projected branch contour set S', generate the plane point set PP, and create the contour Voronoi diagram;

[0008] (4) Extracting segmentation lines based on the Voronoi diagram and storing them in the segmentation line set SL;

[0009] (5) Based on the segmentation line set SL, separate the contour line P to be segmented, obtain the segmented contour lines, and store them in the segmentation contour line set L;

[0010] (6) Based on the projected branch contour set S' and the subdivided contour set L, the matching method is used to complete the contour correspondence.

[0011] Furthermore, step (1) comprises:

[0012] (1-1) Read the branch contour line and store it in the branch contour line set S = {s i |i=1,2,…,DN}; where s i represents the i-th branch contour line, and DN represents the number of branch contour lines;

[0013] (1-2) Read the contour line P to be segmented.

[0014] Furthermore, step (2) includes:

[0015] (2-1) Construct the circumscribed rectangle of the branch contour set S and the circumscribed rectangle of the contour line P to be segmented;

[0016] (2-2) Through coordinate transformation, the branch contour line set S is projected onto the plane where the contour line P is located, so that the circumscribed rectangle of the branch contour line set S and the circumscribed rectangle of the contour line to be segmented P coincide with each other in center and have the same size, and the projected branch contour line set S' = {s' i |i=1,2,…,DN}; where s' i represents the i-th projected branch contour line, and DN represents the number of branch contour lines.

[0017] Furthermore, step (3) includes:

[0018] (3-1) Obtain all contour line vertices in the projected branch contour line set S' and save them to the plane point set PP = {pp j |j=1,2,…,PN}, where pp j represents the jth vertex, PN represents the number of points;

[0019] (3-2) Perform Delaunary triangulation based on the plane point set PP and construct the Delaunary triangulation network T;

[0020] (3-3) Construct Thiessen polygons based on the Delaunary triangulation network T and obtain the Voronoi diagram.

[0021] Further, step (4) includes:

[0022] (4-1) Clip the generated Voronoi diagram, obtain the polygons corresponding to each point in the plane point set PP one by one, and construct the polygon set MP = {mp j|j=1,2,…,PN}, where mp j represents the polygon corresponding to the jth point, and PN represents the number of points;

[0023] (4-2) Obtain polygons belonging to the same branch contour line from the polygon set MP, and obtain each branch contour line s' i Respective polygon sets SP i ;

[0024] (4-3) Merge each polygon set SP i All polygonal faces inside, construct the corresponding subdivision surface m i , store in the subdivision surface set M = {m i |i=1,2,…,DN}, where DN represents the number of subdivision planes;

[0025] (4-4) Obtain any two splitting surfaces in the splitting surface set M and judge whether they are connected. If they are connected, obtain the connecting line as the splitting line sl k , store the segmentation line set SL = {sl k |k=1,2,…,LN}, where LN is the number of segmentation lines.

[0026] Further, step (5) includes:

[0027] (5-1) Convert the contour line P to be segmented from a line to a surface to obtain a segmented contour surface P';

[0028] (5-2) Obtain all the segmentation lines in the segmentation line set SL, cut the segmentation contour surface P', obtain the segmentation contour surface, and store it in the segmentation contour surface set KP';

[0029] (5-3) Convert all the subdivided contour surfaces in the subdivided contour surface set KP' into subdivided contour lines and store them in the subdivided contour line set L = {l o |o=1,2,…,ON}, where l o represents the oth subdivided contour line, and ON represents the number of subdivided contour lines.

[0030] Further, step (6) comprises:

[0031] (6-1) respectively obtaining the center point of the outer rectangle of each projected branch contour line in the projected branch contour line set S' and each subdivided contour line in the subdivided contour line set L;

[0032] (6-2) Calculate the distance between the center point of the outer rectangle of each subdivided contour line and the center point of the outer rectangle of each projected branch contour line. The shorter the distance, the closer they are. Rearrange the order of subdivided contour lines in the subdivided contour line set L according to the degree of proximity. The arranged order is consistent with the order of branch contour lines in the projected branch contour line set S', thereby matching the subdivided contour lines with the branch contour lines.

[0033] The parallel contour line branch processing device based on the Voronoi diagram of the present invention comprises a processor and a computer program stored in a memory and executable on the processor, and the processor implements the above method when executing the program.

[0034] Beneficial effect: Compared with the prior art, the present invention has the following significant advantages: the present invention can not only solve the contour line branching problem efficiently and accurately, but also has a high degree of automation and a small amount of calculation. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] Figure 1 are the branch contour lines and the contour lines to be segmented used in this embodiment (a is a top view, b is a side view);

[0036] Figure 2 is a flow chart of the present invention;

[0037] Figure 3 Schematic diagram of the branch contour after projection in this embodiment (a is a top view, b is a side view);

[0038] Figure 4 is a schematic diagram of the Delaunary triangulation network of this embodiment;

[0039] Figure 5 is a schematic diagram of the Voronoi diagram of this embodiment;

[0040] Figure 6 Schematic diagram of the splitting plane and splitting line of this embodiment (a is the splitting plane, b is the splitting line);

[0041] Figure 7 is the split contour line of this embodiment;

[0042] Figure 8 3D surface reconstruction schematic diagram of the contour line of this embodiment. DETAILED DESCRIPTION

[0043] The technical solution of the present invention is further described in detail below. The experimental data of this embodiment uses the intrusive rock contour line data of a certain research area, such as Figure 1 The following further describes a specific embodiment in conjunction with the accompanying drawings.

[0044] like Figure 2 As shown, the present invention provides a parallel contour line branch processing method based on the Voronoi diagram, which specifically includes the following steps:

[0045] (1) Obtain the contour line P to be segmented and the branch contour line set S.

[0046] This step specifically includes:

[0047] (1-1) Read the branch contour line and store it in the branch contour line set S = {s i |i=1,2,…,DN}; where s i represents the i-th branch contour line, DN represents the number of branch contour lines; Figure 1 As shown, in this embodiment, DN=3;

[0048] (1-2) Read the contour line P to be segmented.

[0049] (2) Project the branch contour line set S to the plane where the contour line P is located through coordinate transformation to obtain the projected branch contour line set S'. In this embodiment, the contour lines before and after projection are as follows: Figure 3 shown.

[0050] This step specifically includes:

[0051] (2-1) Construct the circumscribed rectangle of the branch contour set S and the circumscribed rectangle of the contour line P to be segmented;

[0052] (2-2) Through coordinate transformation, the branch contour line set S is projected onto the plane where the contour line P is located, so that the circumscribed rectangle of the branch contour line set S and the circumscribed rectangle of the contour line to be segmented P coincide with each other in center and have the same size, and the projected branch contour line set S' = {s' i |i=1,2,…,DN}; where s' i represents the i-th projected branch contour line, and DN represents the number of branch contour lines.

[0053] The calculation method of the above coordinate transformation is referenced in the following document: Philip JS, David HE, Geometric Tools for Computer Graphics, Elsevier Science, 2003, p93-95.

[0054] (3) Obtain all contour line fixed points from the projected branch contour line set S', generate the plane point set PP, and create the contour line Voronoi diagram.

[0055] This step specifically includes:

[0056] (3-1) Obtain all contour line vertices in the projected branch contour line set S' and save them to the plane point set PP = {pp j |j=1,2,…,PN}, where pp j represents the jth vertex, PN represents the number of points; in this embodiment, PN=159;

[0057] (3-2) Delaunary triangulation is performed based on the plane point set PP to construct a delaunary triangulation network T. In this embodiment, the triangulation network T is as follows: Figure 4 As shown. The Delaunary triangulation calculation method is referenced in the following documents: Philip J.S., David HE, Geometric Tools for Computer Graphics, Elsevier Science, 2003, p556-558;

[0058] (3-3) Based on the Delaunary triangulation network T, Thiessen polygons are constructed to obtain a Voronoi diagram. In this embodiment, the constructed Voronoi diagram is as follows: Figure 5 As shown. The Voronoi diagram generation method is referenced from the following documents: [1] Liu Shaohua, Luo Xiaolong, He Youbin, Liu Xuefeng, Wu Dongsheng. Research on Thiessen polygon generation algorithm based on Delauany triangulation [J]. Journal of Yangtze University (Natural Science Edition) Science and Engineering Volume, 2007(01):100-103;

[0059] (4) Extract the segmentation lines based on the Voronoi diagram and store them in the segmentation line set SL.

[0060] This step specifically includes:

[0061] (4-1) Clip the generated Voronoi diagram, obtain the polygons corresponding to each point in the plane point set PP one by one, and construct the polygon set MP = {mp j |j=1,2,…,PN}, where mp j represents the polygon corresponding to the jth point, and PN represents the number of points;

[0062] (4-2) Obtain polygons belonging to the same branch contour line from the polygon set MP, and obtain each branch contour line s' i Respective polygon sets SP i ;

[0063] (4-3) Merge each polygon set SP i All polygonal faces inside, construct the corresponding subdivision surface m i , store in the subdivision surface set M = {m i|i=1,2,…,DN}, where DN represents the number of subdivision planes; in this embodiment, the constructed subdivision planes are as follows Figure 6 (a)

[0064] (4-4) Obtain any two split surfaces in the split surface set M for connection judgment. The judgment method is completed using the open source library GDAL. If they are connected, the connection line is obtained as the split line sl k , store the segmentation line set SL = {sl k |k=1,2,…,LN}, where LN is the number of splitting lines. In this embodiment, LN=2, and the splitting lines constructed are as follows Figure 6 (b) as shown.

[0065] (5) Based on the segmentation line set SL, separate the contour line P to be segmented, obtain the segmented contour lines, and store them in the segmentation contour line set L.

[0066] This step specifically includes:

[0067] (5-1) Convert the contour line P to be segmented from a line to a surface to obtain a segmented contour surface P';

[0068] (5-2) Obtain all the segmentation lines in the segmentation line set SL, cut the segmentation contour surface P', obtain the segmentation contour surface, and store it in the segmentation contour surface set KP';

[0069] (5-3) Convert all the subdivided contour surfaces in the subdivided contour surface set KP' into subdivided contour lines and store them in the subdivided contour line set L = {l o |o=1,2,…,ON}, where l o represents the oth segmentation contour line, and ON represents the number of segmentation contour lines. In this embodiment, ON=3, and the segmentation contour lines constructed are as follows Figure 7 shown.

[0070] (6) Based on the projected branch contour set S' and the subdivided contour set L, the matching method is used to complete the contour correspondence.

[0071] This step specifically includes:

[0072] (6-1) respectively obtaining the center point of the outer rectangle of each projected branch contour line in the projected branch contour line set S' and each subdivided contour line in the subdivided contour line set L;

[0073] (6-2) Calculate the distance between the center point of the outer rectangle of each subdivided contour line and the center point of the outer rectangle of each projected branch contour line. The shorter the distance, the closer they are. Rearrange the order of subdivided contour lines in the subdivided contour line set L according to the degree of proximity. The arranged order is consistent with the order of branch contour lines in the projected branch contour line set S', thereby matching the subdivided contour lines with the branch contour lines.

[0074] In this embodiment, the three-dimensional surface reconstruction is performed by the contour line after branching. Figure 8 In the embodiment of the present invention, some GIS operations are provided based on GDAL / OGR, and the relevant steps can also use the API of software such as SuperMap and ArcGIS Object to perform corresponding GIS operations.

[0075] This embodiment also provides a parallel contour line branch processing device based on the Voronoi diagram, including a processor and a computer program stored in a memory and executable on the processor, and the processor implements the above method when executing the program.

[0076] The above disclosure is only a preferred embodiment of the present invention and cannot be used to limit the scope of the present invention. Therefore, equivalent changes made according to the claims of the present invention are still within the scope of the present invention.

Claims

1. A parallel contour line branch processing method based on Voronoi diagram, characterized in that The method includes: (1) Obtain the contour line P to be segmented and the branch contour line set S; (2) Projecting the branch contour line set S onto the plane where the contour line P is located through coordinate transformation to obtain the projected branch contour line set S'; (3) Obtain all contour fixed points from the projected branch contour set S', generate the plane point set PP, and create the contour Voronoi diagram; (4) Extracting segmentation lines based on the Voronoi diagram and storing them in the segmentation line set SL; (5) Based on the segmentation line set SL, separate the contour line P to be segmented, obtain the segmented contour lines, and store them in the segmentation contour line set L; (6) Based on the projected branch contour set S' and the subdivided contour set L, the contour correspondence is completed using the matching method; Step (6) specifically includes: (6-1) respectively obtaining the center point of the outer rectangle of each projected branch contour line in the projected branch contour line set S' and each subdivided contour line in the subdivided contour line set L; (6-2) Calculate the distance between the center point of the outer rectangle of each subdivided contour line and the center point of the outer rectangle of each projected branch contour line. The shorter the distance, the closer they are. Rearrange the order of subdivided contour lines in the subdivided contour line set L according to the degree of proximity. The arranged order is consistent with the order of branch contour lines in the projected branch contour line set S', thereby matching the subdivided contour lines with the branch contour lines.

2. The parallel contour line branch processing method based on the Voronoi diagram according to claim 1, characterized in that: Step (1) comprises: (1-1) Read the branch contour line and store it in the branch contour line set S = {s i |i=1,2,…,DN}; where s i represents the i-th branch contour line, and DN represents the number of branch contour lines; (1-2) Read the contour line P to be segmented.

3. The parallel contour line branch processing method based on the Voronoi diagram according to claim 1, characterized in that: Step (2) comprises: (2-1) Construct the circumscribed rectangle of the branch contour set S and the circumscribed rectangle of the contour line P to be segmented; (2-2) Through coordinate transformation, the branch contour line set S is projected onto the plane where the contour line P is located, so that the circumscribed rectangle of the branch contour line set S and the circumscribed rectangle of the contour line to be segmented P coincide with each other in center and have the same size, and the projected branch contour line set S' = {s' i |i=1,2,…,DN}; where s' i represents the i-th projected branch contour line, and DN represents the number of branch contour lines.

4. The parallel contour line branch processing method based on the Voronoi diagram according to claim 1, characterized in that: Step (3) includes: (3-1) Obtain all contour line vertices in the projected branch contour line set S' and save them to the plane point set PP = {pp j |j=1,2,…,PN}, where pp j represents the jth vertex, PN represents the number of points; (3-2) Perform Delaunary triangulation based on the plane point set PP and construct the Delaunary triangulation network T; (3-3) Construct Thiessen polygons based on the Delaunary triangulation network T and obtain the Voronoi diagram.

5. The parallel contour line branch processing method based on the Voronoi diagram according to claim 1, characterized in that: Step (4) comprises: (4-1) Clip the generated Voronoi diagram, obtain the polygons corresponding to each point in the plane point set PP one by one, and construct the polygon set MP = {mp j |j=1,2,…,PN}, where mp j represents the polygon corresponding to the jth point, and PN represents the number of points; (4-2) Obtain polygons belonging to the same branch contour line from the polygon set MP, and obtain each branch contour line s' i Respective polygon sets SP i ; (4-3) Merge each polygon set SP i All polygonal faces inside, construct the corresponding subdivision surface m i , store in the subdivision surface set M = {m i |i=1,2,…,DN}, where DN represents the number of subdivision planes; (4-4) Obtain any two splitting surfaces in the splitting surface set M and judge whether they are connected. If they are connected, obtain the connecting line as the splitting line sl k , store the segmentation line set SL = {sl k |k=1,2,…,LN}, where LN is the number of segmentation lines.

6. The parallel contour line branch processing method based on the Voronoi diagram according to claim 1, characterized in that: Step (5) comprises: (5-1) Convert the contour line P to be segmented from a line to a surface to obtain a segmented contour surface P'; (5-2) Obtain all the segmentation lines in the segmentation line set SL, cut the segmentation contour surface P', obtain the segmentation contour surface, and store it in the segmentation contour surface set KP'; (5-3) Convert all the subdivided contour surfaces in the subdivided contour surface set KP' into subdivided contour lines and store them in the subdivided contour line set L = {l o |o=1,2,…,ON}, where l o represents the oth subdivided contour line, and ON represents the number of subdivided contour lines.

7. A parallel contour line branch processing device based on a Voronoi diagram, comprising a processor and a computer program stored in a memory and executable on the processor, characterized in that: When the processor executes the program, the method according to any one of claims 1 to 6 is implemented.