Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Polygon clipping method based on intersection point sorting

A polygon and intersection technology, applied in the field of polygon clipping based on intersection sorting, which can solve problems such as algorithm redundancy

Inactive Publication Date: 2012-02-22
ZHEJIANG UNIV
View PDF0 Cites 19 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

However, the intersection point of the algorithm adopts a double-pointer structure. Inserting the intersection point into the solid polygon and clipping the polygon vertex list makes the number of sides participating in the intersection increase due to the increase in the number of polygon vertices, resulting in redundancy in the algorithm. When the number of polygon intersection points When the number is increasing, the impact of repeated intersection calculations on the efficiency of the algorithm is more obvious

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Polygon clipping method based on intersection point sorting
  • Polygon clipping method based on intersection point sorting
  • Polygon clipping method based on intersection point sorting

Examples

Experimental program
Comparison scheme
Effect test

Embodiment

[0059] by figure 1 Example of polygon clipping in

[0060] 1) Take out the first edge of the clipping polygon and the solid polygon, judge whether the two line segments intersect according to the relative positions of the four nodes of the clipping edge and the clipped edge, and analyze the entry and exit of the intersection.

[0061] 2) According to the order of clipping edges, the intersection points are sorted for the first time, and the order obtained is I 0 I 1 I 2 I 3 I 4 C 2 I 5 The intersection linked list, where, I 0 , I 2 , I 4 is the entry point, where C 2 Treat it as a special entry point, I 1 , I 3 , I 5 For the out point. According to the in-out property of the intersection point, a point pair of "in-point-out point" or "in-point-clining polygon vertex-out point" is formed.

[0062] 3) According to the entry and exit of intersection points and the end point serial number of the recorded entity polygon, the pointers of all intersection points are se...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses a polygon clipping method based on intersection point sorting. The polygon clipping method comprises steps including that 1, whether segments are intersected or not is judged according to opposite clipping positions of four intersection points of a clipped side, and in and out properties of the intersection points are analyzed, 2, a solid polygon is subjected to intersection by means of taking sides of a clipped polygon sequentially, whether final points of the clipped sides can form a result polygon or not is judged according to sequence and the in and out properties of the intersection points on each clipped side, vertexes of the clipped polygon forming the result polygon are inserted into an intersection point linked list, and accordingly a point pair consisting of an in point and an out point is formed, 3, pointer directions of all intersection points are set according to the in and out properties of the intersection points and a sequence number of a final point of the recorded solid polygon, vertexes of the solid polygon forming the result polygon are inserted into the intersection point linked list, and secondary sorting of the intersection points is completed, and 4, a result vortex linked list is traversed, and the result polygon is outputted according to the pointer directions. The polygon clipping method has important actual application values in the field of computer graphics.

Description

technical field [0001] The invention relates to the technical field of polygon clipping in computer graphics, in particular to a polygon clipping method based on intersection sorting. Background technique [0002] Cropping is a fundamental operation in graphics. Classical polygon clipping algorithms, such as Sutherland-Hodgeman algorithm, beam-Barsky algorithm, etc., require clipping polygons to be rectangles, but in practical applications, clipping polygons and solid polygons may be general polygons and contain inner rings. Weiler algorithm, Vatti algorithm, and Greiner-Hormann algorithm can process the clipping of general polygons within a certain period of time. Among them, the Weiler algorithm uses a tree data structure, and the Vatti and Greiner-Hormann algorithms use a bilinear linked list data structure. After improving the above three algorithms, Liu Yongkui and others proposed a new polygon clipping algorithm (Liu's algorithm), which optimized the original data str...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Applications(China)
IPC IPC(8): G06T11/00
Inventor 刘仁义杜震洪张丰彭杰何榕健
Owner ZHEJIANG UNIV
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products