US11205285B1 - Method for splicing vector polygon regions with holes - Google Patents

Method for splicing vector polygon regions with holes Download PDF

Info

Publication number
US11205285B1
US11205285B1 US17/144,525 US202117144525A US11205285B1 US 11205285 B1 US11205285 B1 US 11205285B1 US 202117144525 A US202117144525 A US 202117144525A US 11205285 B1 US11205285 B1 US 11205285B1
Authority
US
United States
Prior art keywords
outer frame
edge
overlapping
edges
vector polygon
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.)
Active
Application number
US17/144,525
Inventor
Fei Deng
Siling Yu
Yufan Wang
Yuanxiang Huang
Lina Wang
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Sichuan Tianyi Ecological Garden Group Co Ltd
Chengdu Univeristy of Technology
Original Assignee
Sichuan Tianyi Ecological Garden Group Co Ltd
Chengdu Univeristy of Technology
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Sichuan Tianyi Ecological Garden Group Co Ltd, Chengdu Univeristy of Technology filed Critical Sichuan Tianyi Ecological Garden Group Co Ltd
Assigned to CHENGDU UNIVERSITY OF TECHNOLOGY, SICHUAN TIANYI ECOLOGICAL GARDEN GROUP CO. LTD reassignment CHENGDU UNIVERSITY OF TECHNOLOGY ASSIGNMENT OF ASSIGNORS INTEREST (SEE DOCUMENT FOR DETAILS). Assignors: DENG, FEI, HUANG, YUANXIANG, WANG, LINA, WANG, Yufan, YU, SILING
Application granted granted Critical
Publication of US11205285B1 publication Critical patent/US11205285B1/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation
    • G06T11/20Drawing from basic elements, e.g. lines or circles
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T3/00Geometric image transformations in the plane of the image
    • G06T3/40Scaling of whole images or parts thereof, e.g. expanding or contracting
    • G06T3/4038Image mosaicing, e.g. composing plane images from plane sub-images
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T1/00General purpose image data processing
    • G06T1/20Processor architectures; Processor configuration, e.g. pipelining
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data
    • G06F16/51Indexing; Data structures therefor; Storage structures
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data
    • G06F16/56Information retrieval; Database structures therefor; File system structures therefor of still image data having vectorial format
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/50Image enhancement or restoration using two or more images, e.g. averaging or subtraction
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2210/00Indexing scheme for image generation or computer graphics
    • G06T2210/12Bounding box

Definitions

  • the present invention relates to the technical field of vector graphics splicing, in particular to a method for splicing vector polygon regions with hole
  • neural network In deep learning based on neural network, neural network cannot deal with images with large resolution due to hardware constraints. Therefore, it is necessary to divide the large-resolution images to be processed into a large number of low-resolution images, and then carry out deep learning, and then splice the vectorized graphics.
  • the splicing between vector graphics will lead to overlapping parts of adjacent vector polygons, which makes it impossible to construct a continuous vector polygon region.
  • decorative patterns with complex structures can be seen in some design and manufacturing fields or artworks, and these complex patterns are usually formed by splicing simple graphics.
  • the purpose of the present invention is to provide a method for splicing vector polygon regions with holes.
  • the technical scheme adopted by the present invention is as follows.
  • a method for splicing vector polygon regions with holes comprising the steps of:
  • judging whether there are overlapping parts between the outer frame P 1 and the outer frame P 2 comprises the steps of:
  • performing intersection on the overlapping edges of the outer frame P 1 and the outer frame P 2 comprises the steps of:
  • traversing the data table T to find the connection relationship of edges comprises the steps of:
  • the distance D is less than the preset minimum value, regarding it as an adjacent point, and establishing the connection relationship of the corresponding edges.
  • constructing the splicing of vector polygon regions comprises the steps of:
  • the present invention has the following beneficial effects.
  • the present invention skillfully uses traversing any edge of the outer frame of the vector polygon, so as to remove the overlapping part of the overlapping edge, reduce the calculation workload, and at the same time ensure that the edge stored in the data table is unique, so as to facilitate the later relationship search and establishment.
  • the present invention skillfully uses the minimum distance value to obtain the end point relationship, so as to establish the sequentially connected relationship, which is not affected by the inclination angle and is suitable for splicing various complex vector polygon regions and vector polygon regions containing internal holes.
  • the present invention uses the vector collinear theorem to judge the overlapping of edges, which effectively solves the problem that the vector polygon regions cannot be spliced in any direction in the prior art, and is suitable for many scenes and has high splicing efficiency.
  • the present invention has the advantages of wide application range, high splicing efficiency and the like, and has high practical value and popularization value in the technical field of vector graphics splicing.
  • FIG. 1 is a schematic diagram of splicing vector polygon regions without holes.
  • FIG. 2 is a flowchart of splicing according to the present invention.
  • FIG. 3 is a distribution diagram of overlapping edges of the outer frame of the vector polygon regions according to the present invention.
  • FIG. 4 is a schematic diagram of the internal hole structure of an overlapping edge according to the present invention (AB and CD are overlapping edges).
  • FIG. 5 is a flowchart of an example of splicing vector polygon regions according to the present invention.
  • this embodiment provides a method for splicing vector polygon regions with holes, comprising the following steps.
  • a 1 represents the first vector polygon region
  • a 2 represents the second vector polygon region
  • P 1 represents the outer frame of A 1
  • P 2 represents the outer frame of A 2
  • Table T is used to store the connection relationship of the edges and the edges of the outer frames of two vector polygons
  • Table A is used to store the overlapping edge index of P 1
  • Table B is used to store the overlapping edge index of P 2 .
  • the first step it is judged whether the vector polygon regions A 1 and A 2 are provided with holes. If holes exist, only the outer frames of the vector polygon are used for splicing. Each edge of the outer frame P 1 is traversed, and overlapping judgment is made between the currently traversed edge S of the outer frame P 1 and every edge in the outer frame P 2 . If there is an overlapping part between the edge and S in the outer frame P 2 , the index relationship between the edge S and the overlapping edge of the outer frame P 2 is established and stored in Table A. The above step is repeated to traverse every edge of the outer frame P 2 . The index relationship between the overlapping edge of the outer frame P 2 and the overlapping edge of the outer frame P 1 is established and stored in table B.
  • the outer frame P 1 and the outer frame P 2 are traversed, and the connection relationship of the non-overlapping edges and the edges is stored in table T.
  • the overlapping edge index table A is traversed, and intersection is performed on the overlapping edges of the outer frame P 1 in table A and the overlapping edges corresponding to the index values.
  • the intersection processing is to remove the overlapping parts of the edges and store the intersected connection relationship between the edges in table T.
  • the same operation is used to traverse index table B, and the result is stored in table T.
  • table T is traversed to find the connection relationship for the edge without connection relationship in table T.
  • Finding the connection relationship of edges means finding the adjacent points of edges, which should be searched from back to front in table T. Whether it is an adjacent point can be judged by calculating the distance between the point and the endpoints of all edges in table T (excluding the edge where the point itself is located). If the distance is a minimum value (such as 10 ⁇ circumflex over ( ) ⁇ 8), it can be regarded as an adjacent point.
  • Finding the adjacent point means finding the NearEdge where the adjacent point is located, and the connection relationship between edge and NearEdge is finally established according to the subscript of the adjacent point.
  • all edges in table T are traced and connected to construct polygon frames, and the inclusion relationship between polygon frames is calculated to construct vector polygon regions.
  • all edges in table T are traversed, the previous edge and the next edge of each edge are set, and all vector polygon frames are constructed after finishing traversing. If the number of the finally formed vector polygon frames is greater than 1, it indicates that there are holes in the vector polygon region.
  • All vector polygon frames are traversed, the largest polygon frame of the outer bounding box is found according to the polygon outer bounding box, the small polygon frame is included in the large polygon frame, the polygon frame inclusion relationship is found, and the vector polygon region is constructed.
  • the overlapping edges of the outer frame P 1 and the outer frame P 2 are calculated, and the overlapping edge index relationship tables A and B are established.
  • the overlapping edges of P 2 corresponding to edge 2 of P 1 in table A are 3 and 7, and the overlapping edges of P 1 corresponding to edge 7 and edge 3 in table B are both 2.
  • Tables A and B are traversed, and the overlapping parts of overlapping edges are removed to obtain edges 11 , 12 and 13 .
  • the edges 11 , 12 , 13 and their connection relation are stored in table T.
  • Table T is traversed to find the adjacent points and the edges where the adjacent points are located for the edges without connection relations in table T, and the connection relation between edges and adjacent edges is constructed.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Image Generation (AREA)

Abstract

The present invention discloses a method for splicing vector polygon regions with holes, comprising the steps of: acquiring any two vector polygon regions A1 and A2 to be spliced, the outer frame P1 of A1 and the outer frame P2 of A2; judging whether P1 and P2 have overlapping parts; storing the connection relationship of the non-overlapping edges and the non-overlapping edges of P1 and P2 in a data table T; performing intersection on the overlapping edges of P1 and P2 and storing the overlapping edges in the data table T; traversing the data table T, finding the connection relationship of edges, and constructing the splicing of vector polygon regions. According to the scheme, the present invention has the advantages of wide application range, high splicing efficiency and the like, and has high practical value and popularization value in the technical field of vector graphics splicing.

Description

TECHNICAL FIELD
The present invention relates to the technical field of vector graphics splicing, in particular to a method for splicing vector polygon regions with hole
BACKGROUND
In deep learning based on neural network, neural network cannot deal with images with large resolution due to hardware constraints. Therefore, it is necessary to divide the large-resolution images to be processed into a large number of low-resolution images, and then carry out deep learning, and then splice the vectorized graphics. However, the splicing between vector graphics will lead to overlapping parts of adjacent vector polygons, which makes it impossible to construct a continuous vector polygon region. At the same time, decorative patterns with complex structures can be seen in some design and manufacturing fields or artworks, and these complex patterns are usually formed by splicing simple graphics.
In recent years, some scholars have studied the splicing of vector graphics. Zhou Shizhe and others put forward the concept of a topology descriptor, which determines the splicing mode of both sides of vector graphics. This method can realize the splicing of polygon regions, and construct the vector polygon regions to be spliced into a single object. However, due to the fact that the topology descriptor only contains the information of the splicing mode on both sides of the object, the method limits the splicing of vector polygons to be only spliced along one direction or the opposite direction, so that only one chain vector polygon can be formed, and vector polygons in any direction cannot be spliced. For example, the Chinese invention patent with the Patent Application NO. 201910655043.6 entitled as “Automatic Image Segmentation Method And Device Based On Deep Learning Edge Detection” is provided.
Therefore, it is urgent to propose a method for splicing vector polygon regions with holes, which can solve the problem that the existing methods do not support splicing vector polygon regions extending in any direction, and meet the requirements of removing the overlapping parts when splicing vector polygons in any direction and dealing with internal holes during splicing.
SUMMARY
In view of the above problem, the purpose of the present invention is to provide a method for splicing vector polygon regions with holes. The technical scheme adopted by the present invention is as follows.
A method for splicing vector polygon regions with holes, comprising the steps of:
acquiring any two vector polygon regions A1 and A2 to be spliced, the outer frame P1 of the vector polygon region A1 and the outer frame P2 of the vector polygon region A2;
judging whether the vector polygon region A1 and the vector polygon region A2 are provided with holes, and if holes exist, performing splicing by using the outer frames of the vector polygon regions;
judging whether there are overlapping parts between the outer frame P1 and the outer frame P2, and storing the connection relationship of the non-overlapping edges and the non-overlapping edges of the outer frame P1 and the outer frame P2 in a data table T;
performing intersection on the overlapping edges of the outer frame P1 and the outer frame P2 and storing the overlapping edges in the data table T;
traversing the data table T, finding the connection relationship of edges, and constructing the splicing of vector polygon regions.
Further, judging whether there are overlapping parts between the outer frame P1 and the outer frame P2 comprises the steps of:
traversing each edge of the outer frame P1 sequentially; if there are overlapping parts between the edge of the outer frame P1 and the edge of the outer frame P2, establishing an index relationship between the edge of the outer frame P1 and the edge of the outer frame P2, and storing the index relationship in the overlapping edge index table A;
traversing any edge of the outer frame 2 sequentially; if there are overlapping parts between the edge of the outer frame P2 and the edge of the outer frame P1, establishing an index relationship between the edge of the outer frame P2 and the edge of the outer frame P1, and storing the index relationship in the overlapping edge index table B.
Still further, performing intersection on the overlapping edges of the outer frame P1 and the outer frame P2 comprises the steps of:
performing intersection on the overlapping edges of the outer frame P1 in the overlapping edge index table A and the overlapping edges corresponding to the index values; removing the overlapping parts of the overlapping edges and storing the overlapping edges in data table T;
performing intersection on the overlapping edges of the outer frame P2 in the overlapping edge index table B and the overlapping edges corresponding to the index values; removing the overlapping parts of the overlapping edges and storing the overlapping edges in the data table T.
Further, traversing the data table T to find the connection relationship of edges comprises the steps of:
getting the distance D between the end points of the edge of the outer frame in the data table T;
if the distance D is less than the preset minimum value, regarding it as an adjacent point, and establishing the connection relationship of the corresponding edges.
Further, constructing the splicing of vector polygon regions comprises the steps of:
traversing any edge in the data table T, and setting the previous edge and the next edge of any edge to traverse and form all vector polygon frames, and if the number of vector polygon frames finally formed is greater than 1, indicating that there are holes in the vector polygon regions;
according to the outer bounding box of the formed vector polygon frame, finding the largest polygon frame of the outer bounding box, finding the inclusion relationship of the polygon frame and constructing the vector polygon region.
Compared with the prior art, the present invention has the following beneficial effects.
(1) The present invention skillfully uses traversing any edge of the outer frame of the vector polygon, so as to remove the overlapping part of the overlapping edge, reduce the calculation workload, and at the same time ensure that the edge stored in the data table is unique, so as to facilitate the later relationship search and establishment.
(2) The present invention skillfully uses the minimum distance value to obtain the end point relationship, so as to establish the sequentially connected relationship, which is not affected by the inclination angle and is suitable for splicing various complex vector polygon regions and vector polygon regions containing internal holes.
(3) The present invention uses the vector collinear theorem to judge the overlapping of edges, which effectively solves the problem that the vector polygon regions cannot be spliced in any direction in the prior art, and is suitable for many scenes and has high splicing efficiency.
To sum up, the present invention has the advantages of wide application range, high splicing efficiency and the like, and has high practical value and popularization value in the technical field of vector graphics splicing.
BRIEF DESCRIPTION OF THE DRAWINGS
In order to explain the technical scheme of the embodiments of the present invention more clearly, the following drawings used in the embodiments will be briefly introduced. It should be understood that the following drawings only show some embodiments of the present invention, so they should not be regarded as limiting the scope of protection. For those skilled in the art, other related drawings can be obtained according to these drawings without paying creative labor.
FIG. 1 is a schematic diagram of splicing vector polygon regions without holes.
FIG. 2 is a flowchart of splicing according to the present invention.
FIG. 3 is a distribution diagram of overlapping edges of the outer frame of the vector polygon regions according to the present invention.
FIG. 4 is a schematic diagram of the internal hole structure of an overlapping edge according to the present invention (AB and CD are overlapping edges).
FIG. 5 is a flowchart of an example of splicing vector polygon regions according to the present invention.
DESCRIPTION OF THE EMBODIMENTS
In order to make the purpose, technical scheme and advantages of the present invention clearer, the present invention will be further explained with reference to the drawings and examples, and the embodiments of the present invention include but are not limited to the following examples. Based on the embodiments in the present invention, all other embodiments obtained by those skilled in the art without paying creative labor belong to the scope of protection of the present invention.
Embodiment
As shown in FIG. 1 to FIG. 5, this embodiment provides a method for splicing vector polygon regions with holes, comprising the following steps.
In this embodiment, A1 represents the first vector polygon region, and A2 represents the second vector polygon region. P1 represents the outer frame of A1 and P2 represents the outer frame of A2. Table T is used to store the connection relationship of the edges and the edges of the outer frames of two vector polygons; Table A is used to store the overlapping edge index of P1; Table B is used to store the overlapping edge index of P2.
The structural diagram of a data table T according to the present invention is as follows:
TABLE T
Index Index Endpoint Endpoint
Index quotation quotation subscript of subscript
quotation mark of a mark of a a previous of a
mark previous edge next edge edge next edge
0 1024 1 1 0
1 0 2 1 0
2 1 3 1 0
. . . . .
. . . . .
. . . . .
The structural diagram of an overlapping edge index table A and an overlapping edge index table B according to the present invention is as follows:
TABLE A
Index quotation mark of the Index quotation mark of the
overlapping edge of P1 overlapping edge of P2 and P1
2 3 7
TABLE B
Index quotation mark of the Index quotation mark of the
overlapping edge of P2 overlapping edge of P1 and P2
3 2
7 2
The detailed steps are as follows.
In the first step, it is judged whether the vector polygon regions A1 and A2 are provided with holes. If holes exist, only the outer frames of the vector polygon are used for splicing. Each edge of the outer frame P1 is traversed, and overlapping judgment is made between the currently traversed edge S of the outer frame P1 and every edge in the outer frame P2. If there is an overlapping part between the edge and S in the outer frame P2, the index relationship between the edge S and the overlapping edge of the outer frame P2 is established and stored in Table A. The above step is repeated to traverse every edge of the outer frame P2. The index relationship between the overlapping edge of the outer frame P2 and the overlapping edge of the outer frame P1 is established and stored in table B.
According to the vector collinear theorem and the inclusion relationship of components of each vector in x direction or y direction, overlapping judgment of edges can be made. Assuming that one edge of outer frame P1 is p0 p 1 and one edge of outer frame P2 is p2 p 3, the unit direction vector of edge p0 p 1 can be calculated as:
d 1 ¯ = p 1 - p 0 t 1 ,
and the unit direction vector of p2 p 3 is:
d 2 ¯ = p 3 - p 2 t 2 ,
where t1 is the modulus length of vector p0 p 1 and t2 is the modulus length of vector p2 p 3. If {right arrow over (d)}1×{right arrow over (d)}2=0, according to the vector collinear theorem, it can be known that vectors p0 p 1 and p2 p 3 are parallel or collinear. The unit direction vector of vector p2 p 0 is calculated:
d 3 ¯ = p 2 - p 0 t 3 ,
where t3 is the module length of vector p2 p 0. If {right arrow over (d)}3×{right arrow over (d)}1=0 or {right arrow over (d)}3×{right arrow over (d)}2=0, it can be judged that vectors p0 p 1 and p2 p 3 are collinear according to the properties of the vectors. When the two line segments are not perpendicular to the x direction, it is only necessary to calculate the components of each vector in the x direction. If there is an inclusion relationship between the components, it can be judged that there are overlapping parts between the two line segments; when two line segments are perpendicular to the x direction, it is only necessary to judge whether the components of each vector in the Y direction have an inclusion relationship.
In the second step, the outer frame P1 and the outer frame P2 are traversed, and the connection relationship of the non-overlapping edges and the edges is stored in table T.
In the third step, the overlapping edge index table A is traversed, and intersection is performed on the overlapping edges of the outer frame P1 in table A and the overlapping edges corresponding to the index values. The intersection processing is to remove the overlapping parts of the edges and store the intersected connection relationship between the edges in table T. In the same way, the same operation is used to traverse index table B, and the result is stored in table T.
In the fourth step, table T is traversed to find the connection relationship for the edge without connection relationship in table T. Finding the connection relationship of edges means finding the adjacent points of edges, which should be searched from back to front in table T. Whether it is an adjacent point can be judged by calculating the distance between the point and the endpoints of all edges in table T (excluding the edge where the point itself is located). If the distance is a minimum value (such as 10{circumflex over ( )}−8), it can be regarded as an adjacent point. Finding the adjacent point means finding the NearEdge where the adjacent point is located, and the connection relationship between edge and NearEdge is finally established according to the subscript of the adjacent point.
In the fifth step, according to the connection relationship of edges in table T, all edges are traced and connected to construct polygon frames, and the inclusion relationship between polygon frames is calculated to construct vector polygon regions. First, all edges in table T are traversed, the previous edge and the next edge of each edge are set, and all vector polygon frames are constructed after finishing traversing. If the number of the finally formed vector polygon frames is greater than 1, it indicates that there are holes in the vector polygon region. All vector polygon frames are traversed, the largest polygon frame of the outer bounding box is found according to the polygon outer bounding box, the small polygon frame is included in the large polygon frame, the polygon frame inclusion relationship is found, and the vector polygon region is constructed.
A case is listed for illustration.
(1) The overlapping edges of the outer frame P1 and the outer frame P2 are calculated, and the overlapping edge index relationship tables A and B are established. The overlapping edges of P2 corresponding to edge 2 of P1 in table A are 3 and 7, and the overlapping edges of P1 corresponding to edge 7 and edge 3 in table B are both 2.
(2) According to tables A and B obtained in S1, the edge 2 of the outer frame P1 and the edges 3 and 7 of the outer frame P2 are removed, and the connection relationship between the remaining edges is stored in table T.
(3) Tables A and B are traversed, and the overlapping parts of overlapping edges are removed to obtain edges 11, 12 and 13. The edges 11, 12, 13 and their connection relation are stored in table T.
(4) Table T is traversed to find the adjacent points and the edges where the adjacent points are located for the edges without connection relations in table T, and the connection relation between edges and adjacent edges is constructed.
(5) All edges of table T are tracked and all edges are connected to form a vector polygon frame. The inclusion relationship between polygon frames is found and the vector polygon region is constructed.
The above embodiments are only preferred embodiments of the present invention, rather than limit the scope of protection of the present invention. All changes made by adopting the design principle of the present invention and carrying out non-creative labor on this basis should belong to the scope of protection of the present invention.

Claims (5)

What is claimed is:
1. A method for splicing vector polygon regions with holes, comprising the steps of:
acquiring any two vector polygon regions A1 and A2 to be spliced, the outer frame P1 of the vector polygon region A1 and the outer frame P2 of the vector polygon region A2;
judging whether the vector polygon region A1 and the vector polygon region A2 are provided with holes, and if holes exist, performing splicing by using the outer frames of the vector polygon regions;
judging whether there are overlapping parts between the outer frame P1 and the outer frame P2, and storing the connection relationship of the non-overlapping edges and the non-overlapping edges of the outer frame P1 and the outer frame P2 in a data table T;
performing intersection on the overlapping edges of the outer frame P1 and the outer frame P2 and storing the overlapping edges in the data table T;
traversing the data table T, finding the connection relationship of edges, and constructing the splicing of vector polygon regions.
2. The method for splicing vector polygon regions with holes according to claim 1, wherein judging whether there are overlapping parts between the outer frame P1 and the outer frame P2 comprises the steps of:
traversing each edge of the outer frame P1 sequentially; if there are overlapping parts between the edge of the outer frame P1 and the edge of the outer frame P2, establishing an index relationship between the edge of the outer frame P1 and the edge of the outer frame P2, and storing the index relationship in the overlapping edge index table A;
traversing any edge of the outer frame 2 sequentially; if there are overlapping parts between the edge of the outer frame P2 and the edge of the outer frame P1, establishing an index relationship between the edge of the outer frame P2 and the edge of the outer frame P1, and storing the index relationship in the overlapping edge index table B.
3. The method for splicing vector polygon regions with holes according to claim 2, wherein performing intersection on the overlapping edges of the outer frame P1 and the outer frame P2 comprises the steps of:
performing intersection on the overlapping edges of the outer frame P1 in the overlapping edge index table A and the overlapping edges corresponding to the index values of the overlapping edge index table A; removing the overlapping parts of the overlapping edges and storing the overlapping edges in data table T;
performing intersection on the overlapping edges of the outer frame P2 in the overlapping edge index table B and the overlapping edges corresponding to the index values of the overlapping edge index table B; removing the overlapping parts of the overlapping edges and storing the overlapping edges in the data table T.
4. The method for splicing vector polygon regions with holes according to claim 1, wherein traversing the data table T to find the connection relationship of edges comprises the steps of:
getting the distance D between the end points of the edge of the outer frame in the data table T;
if the distance D is less than a preset minimum value, regarding it as an adjacent point, and establishing the connection relationship of the corresponding edges.
5. The method for splicing vector polygon regions with holes according to claim 1, wherein constructing the splicing of vector polygon regions comprises the steps of:
traversing any edge in the data table T, and setting the previous edge and the next edge of any edge to traverse and form all vector polygon frames, and if the number of vector polygon frames finally formed is greater than 1, indicating that there are holes in the vector polygon regions;
according to the outer bounding box of the formed vector polygon frame, finding the largest polygon frame of the outer bounding box, finding the inclusion relationship of the polygon frame and constructing the vector polygon region.
US17/144,525 2020-10-27 2021-01-08 Method for splicing vector polygon regions with holes Active US11205285B1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202011165576.5 2020-10-27
CN202011165576.5A CN112288631A (en) 2020-10-27 2020-10-27 A vector polygon area stitching method with holes

Publications (1)

Publication Number Publication Date
US11205285B1 true US11205285B1 (en) 2021-12-21

Family

ID=74373351

Family Applications (1)

Application Number Title Priority Date Filing Date
US17/144,525 Active US11205285B1 (en) 2020-10-27 2021-01-08 Method for splicing vector polygon regions with holes

Country Status (2)

Country Link
US (1) US11205285B1 (en)
CN (1) CN112288631A (en)

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050138549A1 (en) * 2003-10-29 2005-06-23 Seiko Epson Corporation Line-of-sight guiding degree calculation system and line-of-sight guiding degree calculation program as well as line-of-sight guiding degree calculation method
US20060089197A1 (en) * 2004-10-27 2006-04-27 Nintendo Co., Ltd., Game apparatus and storage medium storing game program
US20080158251A1 (en) * 2006-12-28 2008-07-03 Sathe Rahul P Real-time collision detection using clipping
US20140233809A1 (en) * 2011-05-13 2014-08-21 Beijing Electric Power Economic Research Institute Method and Device for Processing Geological Information
US8872848B1 (en) * 2010-09-29 2014-10-28 Google Inc. Rendering vector data as tiles
US8983646B1 (en) * 2013-10-10 2015-03-17 Barbara Hanna Interactive digital drawing and physical realization
US20210200218A1 (en) * 2019-12-26 2021-07-01 International Business Machines Corporation Distrubuted vector-raster fusion

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050138549A1 (en) * 2003-10-29 2005-06-23 Seiko Epson Corporation Line-of-sight guiding degree calculation system and line-of-sight guiding degree calculation program as well as line-of-sight guiding degree calculation method
US20060089197A1 (en) * 2004-10-27 2006-04-27 Nintendo Co., Ltd., Game apparatus and storage medium storing game program
US20080158251A1 (en) * 2006-12-28 2008-07-03 Sathe Rahul P Real-time collision detection using clipping
US8872848B1 (en) * 2010-09-29 2014-10-28 Google Inc. Rendering vector data as tiles
US20140233809A1 (en) * 2011-05-13 2014-08-21 Beijing Electric Power Economic Research Institute Method and Device for Processing Geological Information
US8983646B1 (en) * 2013-10-10 2015-03-17 Barbara Hanna Interactive digital drawing and physical realization
US20210200218A1 (en) * 2019-12-26 2021-07-01 International Business Machines Corporation Distrubuted vector-raster fusion

Also Published As

Publication number Publication date
CN112288631A (en) 2021-01-29

Similar Documents

Publication Publication Date Title
Cohen Multiple contour finding and perceptual grouping using minimal paths
CN116385415B (en) A method, apparatus, device and storage medium for edge defect detection
CN113034685B (en) Superposition method, device and electronic equipment of laser point cloud and high-precision map
Pupyrev et al. Improving layered graph layouts with edge bundling
US9317766B2 (en) Method and device for extracting distorted straight line from image
CN113743344B (en) Road information determining method and device and electronic equipment
CN106649817A (en) Three-dimensional pipe model establishment lofting method and device for geography information system
CN106407979A (en) Bill character correction method and device
CN115115535B (en) Depth map denoising method, device, medium and equipment
JP2017215946A (en) Robust method for tracing lines of table
CN115564812A (en) Stereo matching method, system, device and medium based on high-precision parallax refinement
CN114187382A (en) Method, device, equipment and medium for determining map pixel drawing data
US11205285B1 (en) Method for splicing vector polygon regions with holes
CN113901342B (en) Road network data processing method and device, electronic equipment and storage medium
US12190445B2 (en) High-precision map construction method, apparatus and electronic device
CN103837135B (en) Workpiece inspection method and system thereof
CN114577225B (en) A map drawing method, device, electronic device and storage medium
CN116343152A (en) Lane line detection method, device and electronic equipment
EP4024348A2 (en) Method and device for determining boundary points of bottom surface of vehicle, roadside device and cloud control platform
JPH1196392A (en) Geometrical object representation system
JP2940956B2 (en) Line figure feature extraction method
JP4001733B2 (en) Apparatus, system, and method for simplifying annotation on geometric surfaces
CN114693708A (en) Anchor mesh same-row central point matching method and system
CN117575029A (en) Method, device and equipment for determining bridging position in superconducting quantum chip layout
JP2000048052A (en) Layout verification method and layout verification device

Legal Events

Date Code Title Description
FEPP Fee payment procedure

Free format text: ENTITY STATUS SET TO UNDISCOUNTED (ORIGINAL EVENT CODE: BIG.); ENTITY STATUS OF PATENT OWNER: SMALL ENTITY

FEPP Fee payment procedure

Free format text: ENTITY STATUS SET TO SMALL (ORIGINAL EVENT CODE: SMAL); ENTITY STATUS OF PATENT OWNER: SMALL ENTITY

STCF Information on status: patent grant

Free format text: PATENTED CASE

MAFP Maintenance fee payment

Free format text: PAYMENT OF MAINTENANCE FEE, 4TH YR, SMALL ENTITY (ORIGINAL EVENT CODE: M2551); ENTITY STATUS OF PATENT OWNER: SMALL ENTITY

Year of fee payment: 4