CN101533524B - Method for superimposing lines and surfaces - Google Patents

Method for superimposing lines and surfaces Download PDF

Info

Publication number
CN101533524B
CN101533524B CN2008101016177A CN200810101617A CN101533524B CN 101533524 B CN101533524 B CN 101533524B CN 2008101016177 A CN2008101016177 A CN 2008101016177A CN 200810101617 A CN200810101617 A CN 200810101617A CN 101533524 B CN101533524 B CN 101533524B
Authority
CN
China
Prior art keywords
line segment
intersection point
line
blue
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.)
Expired - Fee Related
Application number
CN2008101016177A
Other languages
Chinese (zh)
Other versions
CN101533524A (en
Inventor
朱效民
刘焱
闫杰
申排伟
方金云
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.)
Beijing Zhongke Tongtu Information Technology Co., Ltd.
Original Assignee
Beijing Zhongke Tongtu Information Technology Co Ltd
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 Beijing Zhongke Tongtu Information Technology Co Ltd filed Critical Beijing Zhongke Tongtu Information Technology Co Ltd
Priority to CN2008101016177A priority Critical patent/CN101533524B/en
Publication of CN101533524A publication Critical patent/CN101533524A/en
Application granted granted Critical
Publication of CN101533524B publication Critical patent/CN101533524B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Image Analysis (AREA)

Abstract

The invention provides a method for superimposing lines and surfaces, which comprises the following steps of: calculating line segments on all lines and sides of a polygon based on a scan line algorithm to obtain intersecting line segments belonging to the lines and the sides of the polygon and crossing the same point and then calculating intersecting points of the intersecting line segments; based on the intersecting points, processing the lines with the intersecting point with the polygon to complete the geometric superposition of the lines with the intersection point with the polygon and the polygon; based on representative points on the lines without the intersecting point with the polygon, processing the lines without the intersecting point to complete the geometric superposition of the lines and the polygon; and assigning the results of the geometric superposition with the attribute information of each line and the polygon to complete the superposition of the lines and the polygon. Based on the scan line algorithm, the intersecting points are calculated so as to reduce the computational complexity, thereby reducing the amount of computation; the relationship between the line segments on the lines and the overall polygon is taken into an overall consideration so as to improve the computation efficiency; furthermore, various intersecting points, especially special intersecting points, are processed to improve the robustness of the algorithm, thereby allowing that the algorithm can process all special states.

Description

A kind of method for superimposing lines and surfaces
Technical field
The present invention relates to the research field of computational geometry, computer graphics, further relate to the method for superimposing lines and surfaces of GIS-Geographic Information System (Geographical Information System-GIS) space overlay analysis algorithm.
Background technology
GIS-Geographic Information System is under the support of computing machine hardware and software system, to the relevant geographic distribution data in whole or the part epigeosphere space gather, store, the technological system of management, computing, analysis, demonstration and description.Spatial analysis is the important component part of GIS-Geographic Information System, also is one of leading indicator of estimating a GIS-Geographic Information System function.Spatial analysis is based on the position of geography target and the spatial data analysis technology of morphological feature, its objective is spatial information and the rule extracting and find to imply, is one of basic skills of Spatial Data Mining and Knowledge Discovery.Spatial analysis mainly comprises contents such as amount of space calculation, relational query, buffering analysis, overlay analysis, network analysis, overlay analysis wherein be the present invention the focus that will pay close attention to.In common GIS-Geographic Information System, adopt layered mode to organize geographic landscape, the whole data Layer collection of the same area has been expressed the content of this area's geographic landscape., adopted individual-layer data overlay analysis when being made up.Specifically, overlay analysis is the data Layer that the related subject layer is formed to be superposeed produce the operation of a new data layer, and its result combines original two-layer or attribute that the multilayer key element is had.Overlay analysis not only comprises the stack of spatial relationship, also comprises the comprehensive of relation on attributes.The overlay analysis core is the processing of intersecting line segment, i.e. the stack of the overall situation is through accomplishing having intersection point or handling at the local line segment that end points joins, and two line segments that leave mutually have no meaning to the realization of integral body stack.
The most basic overlay analysis is the operation on two figure layers, suppose to be called input figure layer to first figure layer, and second figure layer is called stacking diagram's layer, then corresponding diagram layer each other between input figure layer and the stacking diagram's layer.In overlay analysis, stacking diagram's layer must be a face figure layer, and input figure layer can be point, line or face figure layer, respectively corresponding point face, line face and the stack of face face.Emphasis of the present invention relates to method for superimposing lines and surfaces.
In the existing public technology, has only the trimming algorithm of single line, i.e. line clipping.For the cutting of big data quantity line, the document that does not have to be correlated with can reference.To every line, its concrete cutting step is following:
1. try to achieve line and polygonal intersection point, and be inserted into intersection point in the storage chains list structure of line and go.Wherein, to some intersecting points of special type,, change into the common intersection point that intersects in twos through minor shifts.Because have only a line and polygonal line segment, so the quantity of line segment is fewer, find intersection generally adopts the violence solving method, promptly to the line segment on the line and polygonal limit find intersection in twos.
2. to the above-mentioned list structure (comprising end points and intersection point) of storage in order, choose first intersection point on a certain section, judge the discrepancy attribute of this intersection point.According to the odd even principle, can obtain the discrepancy attribute of all intersection points.So-called odd even principle promptly, under the situation of properly intersect, line and polygonal all intersection point must be that the point of coming in and going out alternately occurs, and can not have two to go into continuously a little, also can not have two to go out a little continuously.Therefore in case the discrepancy attribute of an end points has obtained, the discrepancy of all the other intersection points has also just obtained.
3. according to intersection point and attribute thereof, obtain part in polygon and outside polygon in order.So promptly accomplished the stack of a line and face.
To sum up, mainly there is the problem of two aspects in existing technology: intersection point is calculated on every limit on every on line line segment and the polygon adopt the violence solving method, the violence algorithm computation speed of calculating so in twos is slow.And for some intersecting points of special type, such as intersecting in situations such as end points, overlapping limits, the line clipping algorithm generally is through small data-bias, changes into common intersection point to intersecting points of special type, has caused the disappearance of precision.Therefore, press for and a kind ofly can effectively reduce algorithm complex and the method for special intersection point special processing.
Summary of the invention
The objective of the invention is to overcome in the existing method for superimposing lines and surfaces, the slow defective of computing velocity that the violence algorithm causes when calculating intersection point, thus a kind of method for superimposing lines and surfaces based on scan-line algorithm is provided.
For realizing above-mentioned purpose, according to an aspect of the present invention, a kind of method for superimposing lines and surfaces is provided, may further comprise the steps:
1) the polygonal limit of line segment on the line of all GIS input figure layers and GIS stacking diagram layer is calculated based on scan-line algorithm, obtain belonging to the crossing line segment of the same point of mistake on said line and polygonal limit, calculate the intersection point of said crossing line segment;
Said step 1) comprises the steps:
11) line segment and the said polygonal limit on the said line of reception obtains the case point structure;
12) from said case point structure, obtain minimum case point, obtain belonging to the crossing line segment of the same point of mistake on said line and polygonal limit, calculate the intersection point of said crossing line segment, upgrade said case point structure; The intersection point of the said crossing line segment of wherein said calculating may further comprise the steps:
121) divide into groups said crossing line segment according to affiliated figure layer, affiliated solid, the group that obtains belonging to different figure layers is right;
122) sort out the distribution scenario of the internal crossing line segment of said group according to the distribution scenario of following four types of crossing line segments; The distribution scenario of wherein said four types of crossing line segments is to obtain according to the bar number of said crossing line segment and the relation between the line segment: red1_blue1, red2_blue1, red1_blue2 and red2_blue2; Red1_blue1 representes the line segment of 1 GIS input figure layer and the line segment of 1 GIS stacking diagram layer; Red2_blue1 representes the line segment of 2 GIS input figure layers and the line segment of 1 GIS stacking diagram layer; Red1_blue2 representes the line segment of 1 GIS input figure layer and the line segment of 2 GIS stacking diagram layers, and red2_blue2 representes the line segment of 2 GIS input figure layers and the line segment of 2 GIS stacking diagram layers;
123), calculate the intersection point of said crossing line segment to affiliated type;
When 13) said case point structure was empty, output had the set of the intersection point of attribute;
2) pair there is the line of intersection point to handle based on this intersection point, accomplishes line and this polygonal geometric superposition that this and polygon have intersection point with polygon;
3), accomplish line and polygonal geometric superposition that this and polygon do not have intersection point based on not having the representative point on the line of intersection point not have the line of intersection point to handle to this and polygon with polygon;
4) the geometric superposition result is composed with every line and polygonal attribute information, accomplish wired and polygonal stack.
According to a further aspect in the invention, four kinds of the distribution scenario that intersects line segment are done further classification, comprising:
In red1_blue1, the distribution scenario that intersects line segment further is divided into: red line segment and blue line segment intersection, join and overlapping;
In red1_blue2, the distribution scenario that intersects line segment further is divided into: red line segment and two blue line segments are respectively to join, join, red line segment and two blue line segments be respectively join, overlapping;
In red2_blue1, the distribution scenario that intersects line segment further is divided into: two red line segments and blue line segment be respectively join, join and two red line segments and blue line segment be respectively join, overlapping;
In red2_blue2, the distribution scenario that intersects line segment further is divided into: two red line segments and two blue line segments all join, the blue line segment is overlapping and two red line segments are overlapping with two blue line segments respectively for red line segment and one.
According to a further aspect in the invention, above-mentioned steps 123) in calculate the intersecting lens section intersection point comprise the steps:
A), belong to GIS input figure layer in the line segment with intersection point place be divided into the red line segment, what belong to GIS stacking diagram layer is divided into the blue line segment;
B), judge the position of second end points on the said red line segment and the position relation of said blue line segment; If said second end points is in the inboard of said blue line segment; Then said intersection point is for going into a little, if said second end points be in the outside of said blue line segment, then said intersection point is for going out a little.
According to a further aspect in the invention, in red1_blue1, when red line segment and blue line segment intersection, the attribute of the intersection point of said crossing line segment comprises a little or goes into a little.
According to a further aspect in the invention, in red1_blue1, when red line segment and blue line segment joined, the intersection point of said crossing line segment did not write down or writes down and its attribute comprises and joining.
According to a further aspect in the invention, in red1_blue1, when red line segment and blue line segment were overlapping, the intersection point attribute of said crossing line segment comprised that beginning is overlapping or finish overlapping.
According to a further aspect in the invention, in red1_blue2, two blue line segments all join with the red line segment and red line segment when crossing over the blue line segment, and the intersection point attribute of said crossing line segment comprises a little or goes into a little.
According to a further aspect in the invention, in red1_blue2, two blue line segments all join with the red line segment and when the same side of red line segment, and the intersection point of said crossing line segment does not write down or writes down and its attribute comprises and joining.
According to a further aspect in the invention, in red1_blue2, when red line segment and a blue line segment were overlapping, the intersection point attribute of said crossing line segment comprised that beginning is overlapping or finish overlapping.
According to a further aspect in the invention, in red2_blue1, two red line segments all join with the blue line segment and when the homonymy of blue line segment, and the intersection point of said crossing line segment does not write down or writes down and its attribute comprises and joining.
According to a further aspect in the invention, in red2_blue1, two red line segments all join with the blue line segment and when the heteropleural of blue line segment, the intersection point attribute of said crossing line segment comprises a little or goes into a little.
According to a further aspect in the invention, in red2_blue1, when a red line segment and blue line segment were overlapping, the intersection point attribute of said crossing line segment comprised that beginning is overlapping or finish overlapping.
According to a further aspect in the invention, in red2_blue2, when two red line segments and two blue line segments joined and do not have cross reference, the intersection point of said crossing line segment did not write down or writes down and its attribute comprises and joining.
According to a further aspect in the invention, in red2_blue2, when two red line segments and two blue line segments joined and have cross reference, the intersection point attribute of said crossing line segment comprised a little or goes into a little.
According to a further aspect in the invention, in red2_blue2, when a red line segment and a blue line segment were overlapping, the intersection point attribute of said crossing line segment comprised that beginning is overlapping or finish overlapping.
According to a further aspect in the invention, in red2_blue2, two red line segments and two blue line segments are not when overlapping fully respectively, and the intersection point of said crossing line segment is record not.
According to a further aspect in the invention; In red2_blue2; Article two, the red line segment overlaps respectively with two blue line segments fully, and the line at two red line segment places is when polygonal limit that two blue line segments belong to overlaps fully, and the intersection point attribute of said crossing line segment comprises overlapping fully.
According to a further aspect in the invention; In red2_blue2; Article two, the red line segment overlaps respectively with two blue line segments fully, and the line at two red line segment places is when polygonal limit that two blue line segments belong to not exclusively overlaps, and the intersection point of said crossing line segment is record not.
According to a further aspect in the invention, above-mentioned steps 2) comprise the steps:
Classify said intersection point according to the line under it;
Belonging to intersection point on each bar line according to series arrangement from the origin-to-destination of said line;
Scan all intersection points successively, and, obtain the part of line outside polygon, in polygon and on Polygonal Boundary respectively, accomplish geometric superposition according to the attribute of intersection point.
According to a further aspect in the invention, above-mentioned steps 3) comprise the steps:
Do not have at said and polygon to choose representative point on the line of intersection point;
Judge representative point and said polygonal relation, and according to representative point in polygon or outside polygon, obtain said and polygon not have the line of intersection point be in polygon or outside polygon, the completion geometric superposition.
Compared with prior art, the present invention can reach following technique effect:
Calculate intersection point based on scan-line algorithm, reduced computational complexity, thereby calculated amount reduces; Take all factors into consideration line segment and whole polygonal relation on the line, improved counting yield; And through to the particularly processing of special intersection point of various intersection points, improved the robustness of algorithm, made algorithm can handle all special situations.
Description of drawings
Below, specify embodiments of the invention in conjunction with accompanying drawing, wherein:
The process flow diagram of the scan-line algorithm that Fig. 1 is among the present invention to be adopted.
Fig. 2 is that heterochromatic line segment position concerns synoptic diagram.
Fig. 3 is a line segment distribution situation classification synoptic diagram of the present invention.
Fig. 4 is a discrepancy attribute synoptic diagram of judging the intersection point that only belongs to a blue line segment.
Fig. 5 is a discrepancy attribute synoptic diagram of judging the intersection point that belongs to two blue line segments.
Fig. 6 is that two red line segments, two polygons of lucky leap and intersection point are the situation synoptic diagram of end points just.
Fig. 7 is a line face stack synoptic diagram.
Embodiment
The present invention at first calculates all line segments of being same point (comprising line segment and the polygonal limit of stacking diagram's layer on the line of input figure layer) based on scan-line algorithm; According to the relation between the line segment of crossing same point; Calculate in each type the attribute that intersects intersection point of line segments, for example go out point, go into point, overlapping point, phase contact etc.; According to the attribute of intersection point, calculate part, part polygon outside and the part on Polygonal Boundary of line in polygon respectively then, also know to be positioned at which polygon inside, promptly accomplish geometric superposition; The polygonal attribute (the then corresponding polygonal attribute in the polygon outside is sky) that is aided with the attribute of line itself to the line geometry body that generates at last and comprises line comprehensively generates stacking diagram's layer.
Calculate intersection point of line segments based on scan-line algorithm, its input information is a series of line segment, comprises the line segment on line and the polygon in online the stack, and output information is the intersection point of these line segments.At first, receive line segment, obtain the case point structure; Then, from the incident dot structure, obtain minimum case point, handle putting related line segment therewith, and deposit this line segment in interim line segment aggregate, these temporary interim line segments are handled the update event dot structure; At last, when the case point structure is sky, promptly calculates and finish.In Fig. 1, the scan-line algorithm flow process has been done corresponding explanation.This algorithm specifically may further comprise the steps:
A, do initialization operation, in the initialization operation process,, and the case point structure Q after the initialization done ordering according to the coordinate of end points with the endpoint initialization case point structure Q of all input line segments; The current activation line segment of initialization bundle R is null set; Setting current all line segment ordered sets is S; Setting current output intersection point set I is null set.
The basic thought of scan-line algorithm is to adopt from left to right all line segments of sequential scanning of a virtual vertical straight line (being sweep trace), up to end.In this scanning process, the line segment that intersects with sweep trace is described current activation line segment.Described current all line segment ordered sets are meant from the geometric element of input and read the line segment that obtains; For example; For arbitrary polygon; Be inserted into polygonal composition line segment in this set and go, after all line segments read end, according to the left end point (then is its lower extreme point to vertical curve) of line segment according to from left to right, from top to bottom order sorts.
B, judge whether Q is null set, if null set then calculates and finishes, I be calculate and the set of intersection point; Otherwise operation is null set until Q below the circulation.
C, from Q, obtain the minimum case point p of coordinate figure, and it is deleted from Q.
D, to search among the R with p be the line segment of terminal point, after this line segment access is in the interim line segment aggregate segs, in R, deletes above-mentioned line segment successively; In delete procedure, the order of R middle conductor can change, and is transformed into adjacently by two adjacent segments that deleted segment by non-conterminous, and the intersection point that calculating possibly exist if there is intersection point, then adds intersection point among the Q to.
E, search among the R line segment through case point p, the line segment access that finds in interim line segment aggregate segs.The order of the line segment that is found is inverted; After the order of R middle conductor changed, there had been new adjacent segments a branch of line segment (possibly be some) the top of this point of process with line segment bottom, calculates possible intersection point; If there is intersection point, then add intersection point among the Q to.
F, from S, choose initial line segment from a p; In S, delete, join among the R, join selected line segment among the segs and go; The new line segment that inserts can cause the variation of R middle conductor order; Calculate the new line segment that inserts and be adjacent intersection point possible between line segment,, then resulting intersection point is added among the Q if there is intersection point.
G, return line segment in the segs, calculate the attribute of the intersection point of line segment in the segs, and be added to an intersection point that calculates among the intersection point set I and go.All line segments among the segs were exactly the line segment of current intersection point, comprised that starting point, terminal point are at current intersection point and through the line segment of current intersection point.Line segment empties in the segs.
Can know from foregoing description; Through including information in the resulting result of calculation of scan-line algorithm, about the figure layer under the starting point coordinate of the packets of information vinculum section of this line segment, terminal point coordinate, the line segment, affiliated solid ID (belong to any bar line segment or belong to which polygon etc.) through the line segment of a certain intersection point.Simultaneously, comprise the two line segment information that produce this intersection point in the information of arbitrary intersection point, so that in the subsequent calculations, sort according to the ownership antinode of intersection point.
In aforesaid step g, return line segment in the segs, calculate the intersection point attribute, can carry out through following method.Divide into groups through line segments of same points these according to affiliated figure layer, affiliated solid, then to all groups to handling.
At first divide into groups according to affiliated figure layer, promptly input figure layer respectively becomes one group with line segment on stacking diagram's layer; Then, carry out secondary according to the solid ID under each line segment again and divide into groups, assign to a group such as the line segment that belongs to same polygon or belong to the same line.Make up two groups that belong to different figure layers, it is right to form a group, and obtaining belonging to the different institutes that scheme the line segment distribution pattern of layer and process same point that belong to different solids might combination situations.Because free-throw line or polygon geometry can not be more than two, so the line segment number of each group is at most two through the limit on same summit.For the line segment that belongs to stacking diagram's layer, because stacking diagram's layer is a face figure layer, so these line segments must be polygonal limits, if intersection point then must have two line segments that belong to this face figure layer to cross this point at the endpoint location of this type of line segment just.
Through above-mentioned division operation; According to the line segment quantity that belongs to same solid in the line segment of crossing same intersection point, the line segment situation of crossing same point is divided into four groups: red1_blue1, red2_blue1; Red1_blue2; Red2_blue2, wherein the red representative belongs to the line segment of input figure layer, promptly forms the line segment of line geometry body; The blue representative belongs to the line segment of stacking diagram's layer, promptly forms polygonal line segment.The number of 1 or 2 expression line segments, for example: the line segment that the blue1 representative belongs to stacking diagram's layer is 1, and further, red1_blue1 representes in this group line segment distribution scenario the line segment of an input figure layer and the line segment of stacking diagram's layer are arranged, and other are analogized.
In above-mentioned four groups, the distribution of line segment has nothing in common with each other again.Contact relation according between the line segment is classified.Through the contact relation between the line segment of same point comprise crossing, join and overlapping.Wherein joining refers to that two line segments only have a public coincide point, and coincide point is the end points of at least one line segment; Intersect and to be meant that two line segments only have a public coincide point, and coincide point not the end points of arbitrary line segment; Overlap with overlapping fully overlapping comprising.The number of resulting line segment relation is the line segment number of red and the amassing of line segment number of blue, as: the relation between the line segment that red2_blue2 obtains has four.Then, concern according to the position of line segment and carry out disaggregated classification.Particularly, when two line segments are arranged, need to consider that heterochromatic line segment be to cross over these two line segment institute's area surrounded or only contact two line segment area surrounded for any, this situation is as shown in Figure 2, and wherein a is the former synoptic diagram, and b is latter's synoptic diagram.Determination methods to line segment position relation is following: for example judge that two line segment m1, n1 are whether at the homonymy of line segment k1; Get the end points of m1 and the non-common intersection of n1; Terminal A 1 and B1 in promptly scheming; And two the end points C1 of k1 and D1, calculate the leg-of-mutton oriented area that triangle that A1, C1 and D1 constitute and B1, C1 and D1 constitute respectively.If two areas positive and negative identical, then m1, n1 are at the homonymy of k1; Otherwise heteropleural at k1.
Concern disaggregated classification through above-mentioned according to the classification of line segment contact relation with according to the line segment position, the whole distribution situation classification of line segment are as shown in Figure 3, and the line segment that wherein belongs to input figure layer dots, and the line segment that belongs to stacking diagram's layer is represented with solid line.
For red1_blue1, because solid line is the line segment that belongs on stacking diagram's layer among the figure, it is a polygonal limit, so intersection point can not be at the end points of blue line segment, otherwise belongs to the situation of red1_blue2.According to the relation between above-mentioned analysis and two line segments, obtaining possible situation has following five kinds: one is two line segment intersections, like the 1-1 among Fig. 3; The 2nd, the red line segment contacts at end points with the blue line segment, like the 1-2 among Fig. 3; Three be two line segments overlap and end points not overlapping, like the 1-3 among Fig. 3; The 4th, the blue line segment is comprised by the red line segment, and promptly its another end points overlaps, like the 1-4 among Fig. 3; The 5th, the blue line segment is inner at the red line segment, and promptly the blue line segment is the part of red line segment, and has no end points to overlap, like the 1-5 among Fig. 3.In a word, in the assorting process of this group of red1_blue1, just classify according to the contact relation between two line segments; And the line segment according to blue must be the characteristics from a polygonal limit, obtains possible five types.
For red1_blue2, have 9 kinds of situation, need to calculate the relation between the line segment twice, promptly two blue line segments respectively with the relation of red line segment.At this moment, the common point of red line segment and two blue line segments must be the end points of two blue line segments, and the red line segment is through end points.Therefore, the relation between the possible line segment is: join, join; Join, overlapping.For joining, join type; The line segment of blue must comprise a delta-shaped region, or the polygon at blue place is inner or outside, though the red line segment all joins with the relation of two blue line segments so; But possibly be that the red line segment is crossed over the blue zone; Also possibly be that the red line segment is always in the same side in blue zone, like the 2-1 among Fig. 3, shown in the 2-2.2-1 passes through polygon, and 2-2 contacts and mistake with polygon.Also having a kind of situation is 2-3 among Fig. 3, and promptly the end points of two blue lines is the end points of red line segment just.For join, overlapping type, like 2-4 among Fig. 3,5,6,7,8, shown in 9.Wherein overlapping described in red1_blue1, at another end points place of position overlapped, possibly be that end points overlaps or do not overlap, do not overlap and be divided into two kinds: red line segment end points is comprised by the blue line segment or blue line segment end points is comprised by the red line segment.
Similarly, red2_blue1 has 5 kinds of situation and belongs to two types: join, join; Join, overlapping.The type of wherein joining, join is divided into 3-1 among Fig. 3; Two kinds of situations of 3-2,3-1 is the zone of two red line segments contact blue line segment representative, promptly two red line segments are at the homonymy of blue line segment; 3-2 is that two red line segments are crossed over the blue line segment, and promptly two red line segments are at the heteropleural of blue line segment.Join, 3-3 among overlapping type such as Fig. 3,3-4 is shown in the 3-5.
Co-exist in 14 kinds of situation for red2_blue2 according to the relation between four line segments.Totally can be divided into following three kinds: only join; Article one, overlapping; Article two, all overlapping.To the situation of only joining, the line segment of promptly any two different figure layers all is the relation of joining.Like 4-1 among Fig. 3, shown in the 4-2; The two difference is that two line segments cross one another, and like Fig. 4-2, still only joins like Fig. 4-1.For an overlapping situation, 4-3 among total Fig. 3,4,5 these three kinds of situation.For two all overlapping situations, have 3 * 3=9 kind situation, shown in 4-6 to 4-14 among Fig. 3.
The present invention classifies according to the relation between the line segment, and accompanying drawing is signal just, and not representing the computation process middle conductor is exactly according to illustrated direction or angle.In the practical application, if the contact relation between the line segment satisfy intersect, join, overlapping etc., just incorporate it into corresponding classification.As long as the contact relation between the line segment has been confirmed, and the local location of the geometry entity of line segment representative relation is definite, so the processing of these line segments has just been confirmed.
It is fashionable to handle every kind of different sets of line segments; Its basic calculating is to judge that the intersection point between two line segments goes out a little or goes into a little; Can obtain at second end points on its direction and the relation between polygonal blue line segment according to the red line segment; Even second end points is in the inboard of current blue line segment, for going into a little; Otherwise for going out a little.Certainly as if first end points with the red line segment, then its attribute of coming in and going out becomes anti-just, and promptly first end points is a little when the inboard, is into point when the outside.In above-mentioned deterministic process; Line segment all is directive, and every line segment all has two end points, is exactly first related among the application end points along first end points of line segment direction; Accordingly, second end points along line segment direction is exactly second related among the application end points.
As shown in Figure 4, suppose to have two line segment A, B to intersect, their intersection point is C, the direction of line segment A is for to the right, and the direction of line segment B is for making progress.Need below to judge that intersection point C is for going out a little still to go into a little.Usually, an intersection point is into point, just represent that a line segment is entering into a polygonal inside through behind this intersection point, and an intersection point is a little, just representes that a line segment walking out polygonal inside through behind this intersection point.Therefore, judge that intersection point C goes out a little or goes into a little, will see that line segment A will belong to polygonal inside or walk out line segment B to belong to polygonal inside through a C entering line segment B.Can know that from Fig. 4 the C point is for going into a little.But in actual deterministic process; Usually can not know directly that line segment B belongs to polygonal shape and position, for line segment B, it both maybe be as shown in the figure; For the limit (right side that is the limit is the polygon interior zone) in its polygonal region left side, place, also possibly be the limit on polygon right side, place.If line segment B is the limit on its polygon right side, place, then put C then for going out a little.Therefore; Provided in the present invention according to the direction of line segment and judged that the intersection point between two line segments goes out a little or go into determination methods a little: if second end points of line segment is in the inboard of intersecting line segment; Then intersection point is for going into a little, if second end points of line segment be in the outside of intersecting line segment, then intersection point is for going out a little.When adopting said method to judge, a precondition is that the polygonal direction that line segment belongs to is fixed.In the present invention, suppose that it is CW that the blue line segment belongs to polygonal direction outer shroud, interior ring is counterclockwise.Therefore, just can know the polygonal general location in place according to the direction of blue line segment.For example, the direction of known line segment B upwards, then according to CW, and line segment B belongs to polygonal outer shroud, then line segment B place polygon is identical with polygon in scheming.After definite polygon direction, just can judge inboard and the outside.When judging the described inboard or the outside, relevant with the direction of crossing line segment.For example, the direction of the line segment B among the figure upwards, then the right side of line segment B is exactly described inboard, if being directed downwards of line segment B, then the left side of line segment B is described inboard, and the right side of line segment B is the outside.Need to prove, in above-mentioned deterministic process, at second end points judging whether when intersecting line segment inboard; And do not mean that described second end points must belong to polygonal inside at crossing line segment; Still be example with Fig. 4, second end points of line segment A belongs to polygonal outside at line segment B, but owing to the right side of this end points at line segment B; Therefore can think that still second end points in the inboard of line segment B, makes intersection point C for going into a little.Can know through above-mentioned explanation, utilize two crossing line segments that have direction, can know that the intersection point of two crossing line segments goes out a little or goes into a little.
Said method is to calculate with respect to a blue line segment.If case point is polygonal end points just, it also is two these red line segments of blue line segments process that polygonal two limits are promptly arranged, and need the position relation of a point and two adjacent sides be made a decision.Its determination methods is following:
The judgement of this position relation is not to obtain current point whether to be positioned at polygonal inside, but for two limits, whether this point goes out a little or go into a little thereby obtain intersection point in the inboard on these both sides.As shown in Figure 5, current known line segment is promptly with red line segment and two broad-brush blue line segments of arrow.Current required calculating judges that promptly second end points of the red line segment of band arrow is the position relation of the end points and the two thick lines blue line segments at arrow place.Judge that at first two blue line segments are clockwise or counterclockwise.If clockwise and be polygonal outer shroud, then shown in the blue solid line of the similar hachure of its polygon, then the end points at arrow place is in the inboard of two blue line segments (though maybe in polygonal inside).Concrete implementation method is: at first judge the direction of two adjacent sides, clockwise perhaps counterclockwise.Two adjacent sides are divided into four parts to plane domain, and are as shown in the figure, and this four part is the left side, a left side of corresponding two line segments respectively, about, a right left side, right zone.If two adjacent sides are clockwise, then right zone is only polygonal inside region, and remaining is all polygonal exterior lateral area; If two adjacent sides are counterclockwise, then left zone is polygonal exterior lateral area, and all the other zones all are polygonal inboards.For interior ring and outer shroud, above rule all is suitable for.So, according to the direction of two adjacent sides, and the point and the relation of two line segments, can obtain point outside the inboard of two line segments still is, go out a little or go into a little thereby obtain intersection point.
Especially, explain the intersection point of the situation that overlaps is handled.For any situation that overlapping generation is arranged; Needing this point of record is that beginning is overlapping or end is overlapping; Calculation Method is promptly according to the relative position relation of the terminal point of starting point, current event spot and the current red line segment of current red line segment, and just walking of line segment always confirms.For the two-end-point of red line segment do not drop on the blue limit fully or its extended line on situation when the outside (just can calculate inboard that at least one end points drops on the blue line still), then need go out a little or go into a little according to position this intersection point of relation calculating on end points and blue limit.
Go out a little according to the intersection point between two line segments of above-mentioned judgement below or go into point methods, respectively every kind of line segment distribution scenario is processed.
Red1_blue1 situation: for the properly intersect situation shown in the 1-1 of Fig. 3, calculate the discrepancy attribute of intersection point, preserve.For shown in the 1-2 of Fig. 3 in the end points situation of joining, generally can not include intersection point; Certainly according to some special demand, there is not the contact of line face the real situation that intersects to can be regarded as intersection point such as requiring yet, then can write down such point is intersection point, the intersection point attribute is set to join and gets final product.For the 1-3,4 of Fig. 3, three kinds of situations shown in 5, write down current intersection point, and set a property to overlapping, further moving towards to calculate according to the red line segment is that beginning is overlapping or end is overlapping.In addition, be conllinear because current blue line segment only has one and red line segment and blue line segment, therefore can't obtain this intersection point according to the relation of red line segment and blue line segment and go out a little or go into a little, so also just not calculate into attribute.Can get from synoptic diagram, current intersection point must be the starting point or the terminal point (if intermediate point then must also have a line segment in the position of current point) of the sliver at red line segment place.
The Red1_blue2 situation: for the properly intersect situation shown in the 2-1 of Fig. 3, the optional line segment of two blue line segments as the generation intersection point, and calculate red line segment discrepancy attribute.For the 2-2 of Fig. 3, situation shown in 3, the needs that whether write down according to intersection point to this type of joining, or be recorded as the intersection point of the attribute that joins or be not recorded as intersection point.If record intersection point, the discrepancy that yet can calculate intersection point is not though polygon is not really walked out or enter into to line.For 2-4,5,6; As shown in the figure; The end points of red line segment does not overlap with current case point (just current intersection point), and another end points of red line segment possibly be positioned at the inside of blue line segment, overlapping end points or outside, promptly respectively corresponding three kinds of situations.For these three kinds of situations, need be that beginning is overlapping or end is overlapping according to the current intersection point of mark that moves towards of red line segment.Simultaneously, also will according to nonoverlapping that end points of red line segment and blue line segment (with the red line segment nonoverlapping that) the position relation calculate, go out a little or go into a little to obtain current intersection point.Just, to above-mentioned three kinds of situations, need start-of-record overlapping still finish overlapping, and the discrepancy attribute that calculates intersection point.For 2-7,8,9 three kinds of situations, with 2-4,5,6 difference is that current case point (being intersection point) is the end points of red line segment just, and is a distal point (if not distal point must be crossed this point and also have the red line segment).Except with the above-mentioned overlapping corresponding end points of end points, another end points of red line segment and blue line segment have three kinds of relations:, overlapping end points inner at the blue line segment or outside, with last 2-4,5,6 is similar.In the inside of blue line segment or end points when overlapping, then do not calculate the discrepancy attribute of this intersection point for another end points, the processing of this and red1_blue1 is similar.For the outside of end points, then can obtain the discrepancy attribute of current intersection point according to the position relation of this end points and blue line segment (that blue line segment that does not overlap with the red line segment) and the trend of red line segment at the blue line segment.But no matter which kind of situation, all need write down this intersection point is that beginning is overlapping or end is overlapping.
The Red2_blue1 situation: for situation shown in the 3-1 of Fig. 3, the needs that in like manner can whether write down according to intersection point to this type of joining, or be recorded as the intersection point of the attribute that joins or be not recorded as intersection point.Situation can be regarded as the intersection point of properly intersect shown in the 3-2 of Fig. 3, and the red line segment is chosen in an inboard line segment as the generation intersection point of the corresponding polygon of blue line segment.For intersecting points of special type, as shown in Figure 6 like this, promptly two red line segments (shown in dotted line among the figure) are crossed over two polygons (shown in solid line among the figure) just, and intersection point is end points just.According to aforesaid way; Be chosen at the inner line segment of polygon as the blue line segment that produces intersection point; Promptly to the line segment of choosing the left side in left side, the polygon on right side is then chosen the line segment on right side as the line segment that produces intersection point, in this way; Two intersection points that then have same coordinate have been divided on two line segments, made things convenient for the intersection point on the line segment is sorted.If second group of polygon has only a polygon, then need not haggle over and choose any bar line segment as the line segment that produces intersection point.For 3-3,4,5 three kinds of situations because there is a limit not overlapping, therefore need calculate the discrepancy attribute of current intersection point.Coming in and going out, the position of calculating that nonoverlapping end points through nonoverlapping red line segment and blue line segment of attribute concerns and the trend of red line segment can obtain.Simultaneously, all intersection point all will according to the red line move towards start-of-record overlapping still finish overlapping.
Red2_blue2 situation: for situation shown in the 4-1 of Fig. 3, according to demand history join type intersection point or record intersection point not.For situation shown in the 4-2 of Fig. 3, the intersection point of record properly intersect, similar with the 3-2 situation of Fig. 3, the red line segment also is chosen at the line segment that the inner conduct of the corresponding polygon of blue line segment produces intersection point.For 4-3,4, the situation shown in 5 of Fig. 3,, need to calculate the discrepancy attribute of intersection point because there have a limit not have to be overlapping; Also need be according to the trend of red line segment, record intersection point is that beginning is overlapping or end is overlapping.For situation shown in the 4-6 to 14 of Fig. 3; If the red line segment is not to overlap fully (promptly to put the position endways with the blue line segment; End points overlaps fully), then because its overlapping must be from some some opening entry, the intersection point here just continues its overlapping part; Do not stop, so do not write down any intersection point; If the red line segment overlaps with the blue line segment just fully, need judge then whether the line of red line segment representative overlaps with the polygon of blue line segment representative fully, and just whether the order of each point coordinate and point overlaps fully.This judgement is to carry out according to the data structure of the data structure of red line segment and blue line segment; Wherein comprise a pointer that points to the affiliated line of red line segment in the data structure of red line segment; The blue line segment is also similar, promptly can obtain all end points coordinate figures of whole line or face solid through this line segment.If overlap, then write down current intersection point, and it is overlapping into fully to set a property, after this scan such point and promptly obtain this line and overlap fully with polygonal border.If not exclusively overlap, but overlap with the blue line segment at this some red of place line segment, promptly the part of line overlaps with polygonal limit, then need not record intersection point.This is because this only is the continuity of lap, and therefore never overlapping onto overlapping part must have boundary's point, and that boundary's point is inevitable is done intersection point by note.
After obtaining intersection point according to above-mentioned scan-line algorithm, based on intersection point be point, go into point, join, attribute such as overlapping pair has the line of intersection point to handle with polygon, obtains the information of line, for example: the part of line outside polygon and the part in polygon; Which for the part in polygon, also can obtain in polygon according to the polygonal ID that produces intersection point.
To all intersection point orderings, at first sort according to the line under it, all intersection points that promptly belong on the same line are put together, and sort according to the ID of line; Then these are belonged to the intersection point on the same line, sort, finally make intersection point on the every line according to series arrangement from origin-to-destination according to the line segment direction under it.Scan all intersection points successively, and according to the discrepancy of intersection point, and begin overlapping, stop attributes such as overlapping, obtain the part polygon outside, in polygon and on Polygonal Boundary respectively, the completion geometric superposition.Begin from the starting point of line segment, if run into the overlapping point of beginning (can not at first run into and finish overlapping point), then ignore its attribute of coming in and going out, find next intersection point (must be to finish overlapping point), what obtained this moment must be the part overlapping with polygonal border.For not being overlapping part, the line that then obtains this generation according to the attribute of corresponding two intersection points (being the Origin And Destination of this line) of the line that produces is in polygonal inside or outside.Go into a little and the part between going out a little must be inner at polygon; Going out a little and the part between going into a little, must be at outside of polygon.Have only one to be intersection point and another is the situation of end points (being the starting point or the terminal point of original incoming line) for two lines that produce, then the attribute according to an intersection point can obtain.If to going into a little, then is the part at outside of polygon from starting point; Starting point then is the inner part of polygon to going out a little.Going out a little to breast the tape, then is exterior section; Going into a little to breast the tape, then is interior section.Need to prove, the part as a result of any generation, if a corresponding starting point or terminal point that end points is the initial input line, then another intersection point must be that the intersection point of attribute of coming in and going out is arranged, and can not be not calculate the point into attribute described in the aforementioned calculation.As shown in Figure 7 for example, after trying to achieve all intersection points and ordering, the sequential scanning intersection point.If first intersection point is a little, then starting point is promptly inner at polygon to this intersection point part; Otherwise at outside of polygon.All intersection points of sequential scanning afterwards according to the discrepancy and the overlapping attribute of two intersection points, obtain two line segment and this part line segments between the intersection point in polygon still outside the polygon, up to scanning terminal point in order.
Above-mentioned calculate all intersection points through scan-line algorithm after, can obtain having the line and the polygonal geometric superposition result of intersection point with polygon according to intersection point.In addition, also there are some lines and polygon not to produce any intersection point.For not having the line of intersection point then to choose representative point, judge representative point and polygonal relation then, and in polygon or outside polygon, to obtain incoming line be in polygon or outside polygon according to point, the completion geometric superposition with polygon.Similarly, for the line in polygon, which polygon has also just obtained is in.
Above-mentioned the line that produces intersection point with polygon and do not produce intersection point is handled respectively after, promptly obtain the line segment outside polygon, the line segment in polygon.And,, write down polygonal ID simultaneously for the line segment in polygon.According to different overlap-add operation; Can obtain the part outside polygon or in polygon; And can generate the key element (comprising solid information and attribute information) that has attribute information (the geography information meaning is promptly arranged) according to the ID of solid under the line segment (ID and the polygonal ID that comprises the blue line segment that comprise the incoming line of red line segment) inherited attribute.The polygonal attribute that the result who also promptly generates inherits its original attribute and comprises line.Such as the bar expressway being arranged Beijing-Shanghai high speed, and individual polygon is arranged is the Shandong Province, then obtains behind the inner part circuit in Shandong Province, and the result who obtains has its geographic significance: Beijing-Shanghai high speed (inheriting the attribute of coming from line), Shandong Province (inheriting the attribute of coming from face).Comprehensively generate figure layer and preservation to these key elements then, promptly accomplished the operation of whole stack.
Used scan-line algorithm, the present invention not only through to the particularly processing of special intersection point of various intersection points, has improved the robustness of algorithm, makes algorithm can handle all special situations; But also obtain line segment and whole polygonal relation, thereby improved the speed of calculating intersection point through the relation of calculating local line segment.Table 1 has been described and has been used the present invention and ArcGIS product experimental data result respectively:
Table 1 the present invention and ArcGIS test figure contrast table
Input figure layer line hop count The intersection point number Adopt the time of the present invention (second) The time of ArcGIS (second)
924951 49446 20 32
924951 205269 123 357
924951 317237 191 508
924951 522506 327 842
As shown in table 1, for same experimental data, the present invention compares with the ArcGIS product, and the calculating needed time of intersection point obviously reduces.Be 924951 for input figure layer line hop count for example, and these line segments have the test figure of 205269 intersection points, the time required for the present invention is 123 seconds, and ArcGIS product needed 357 seconds.
Should be noted that and understand, under the situation that does not break away from the desired the spirit and scope of the present invention of accompanying Claim, can make various modifications and improvement the present invention of above-mentioned detailed description.Therefore, the scope of the technical scheme of requirement protection does not receive the restriction of given any specific exemplary teachings.

Claims (20)

1. method for superimposing lines and surfaces that is applied among the GIS may further comprise the steps:
1) the polygonal limit of line segment on the line of all GIS input figure layers and GIS stacking diagram layer is calculated based on scan-line algorithm, obtain belonging to the crossing line segment of the same point of mistake on said line and polygonal limit, calculate the intersection point of said crossing line segment;
Said step 1) comprises the steps:
11) line segment and the said polygonal limit on the said line of reception obtains the case point structure;
12) from said case point structure, obtain minimum case point, obtain belonging to the crossing line segment of the same point of mistake on said line and polygonal limit, calculate the intersection point of said crossing line segment, upgrade said case point structure; The intersection point of the said crossing line segment of wherein said calculating may further comprise the steps:
121) divide into groups said crossing line segment according to affiliated figure layer, affiliated solid, the group that obtains belonging to different figure layers is right;
122) sort out the distribution scenario of the internal crossing line segment of said group according to the distribution scenario of following four types of crossing line segments; The distribution scenario of wherein said four types of crossing line segments is to obtain according to the bar number of said crossing line segment and the relation between the line segment: red1_blue1, red2_blue1, red1_blue2 and red2_blue2; Red1_blue1 representes the line segment of 1 GIS input figure layer and the line segment of 1 GIS stacking diagram layer; Red2_blue1 representes the line segment of 2 GIS input figure layers and the line segment of 1 GIS stacking diagram layer; Red1_blue2 representes the line segment of 1 GIS input figure layer and the line segment of 2 GIS stacking diagram layers, and red2_blue2 representes the line segment of 2 GIS input figure layers and the line segment of 2 GIS stacking diagram layers;
123), calculate the intersection point of said crossing line segment to affiliated type;
When 13) said case point structure was empty, output had the set of the intersection point of attribute;
2) pair there is the line of intersection point to handle based on said intersection point, accomplishes line and said polygonal geometric superposition that said and polygon have intersection point with polygon;
3), accomplishes line and said polygonal geometric superposition that said and polygon does not have intersection point based on not having the representative point on the line of intersection point not have the line of intersection point to handle with polygon to said with polygon;
4) said geometric superposition result is composed with every line and polygonal attribute information, accomplish line and said polygonal stack.
2. the method for superimposing lines and surfaces that is applied among the GIS according to claim 1 is characterized in that, four kinds of the distribution scenario of said crossing line segment are done further classification, comprising:
In red1_blue1, the distribution scenario of said crossing line segment further is divided into: red line segment and blue line segment intersection, join and overlapping;
In red1_blue2, the distribution scenario of said crossing line segment further is divided into: red line segment and two blue line segments are respectively to join, join, red line segment and two blue line segments be respectively join, overlapping;
In red2_blue1, the distribution scenario of said crossing line segment further is divided into: two red line segments and blue line segment be respectively join, join and two red line segments and blue line segment be respectively join, overlapping;
In red2_blue2, the distribution scenario of said crossing line segment further is divided into: two red line segments and two blue line segments all join, the blue line segment is overlapping and two red line segments are overlapping with two blue line segments respectively for red line segment and one.
3. the method for superimposing lines and surfaces that is applied among the GIS according to claim 2 is characterized in that step 123) described in calculate said crossing line segment intersection point comprise the steps:
A), belong to GIS input figure layer in the line segment with intersection point place be divided into the red line segment, what belong to GIS stacking diagram layer is divided into the blue line segment;
B), judge the position of second end points on the said red line segment and the position relation of said blue line segment; If said second end points is in the inboard of said blue line segment; Then said intersection point is for going into a little, if said second end points be in the outside of said blue line segment, then said intersection point is for going out a little.
4. the method for superimposing lines and surfaces that is applied among the GIS according to claim 3 is characterized in that, in red1_blue1, when red line segment and blue line segment intersection, the intersection point attribute of said crossing line segment comprises a little or goes into a little.
5. the method for superimposing lines and surfaces that is applied among the GIS according to claim 3 is characterized in that, in red1_blue1, when red line segment and blue line segment joined, the intersection point of said crossing line segment did not write down or writes down and its attribute comprises and joining.
6. the method for superimposing lines and surfaces that is applied among the GIS according to claim 3 is characterized in that, in red1_blue1, when red line segment and blue line segment were overlapping, the intersection point attribute of said crossing line segment comprised that beginning is overlapping or finish overlapping.
7. the method for superimposing lines and surfaces that is applied among the GIS according to claim 3; It is characterized in that; In red1_blue2, two blue line segments all join with the red line segment and red line segment when crossing over the blue line segment, and the intersection point attribute of said crossing line segment comprises a little or goes into a little.
8. the method for superimposing lines and surfaces that is applied among the GIS according to claim 3; It is characterized in that; In red1_blue2, two blue line segments all join with the red line segment and when the same side of red line segment, and the intersection point of said crossing line segment does not write down or writes down and its attribute comprises and joining.
9. the method for superimposing lines and surfaces that is applied among the GIS according to claim 3 is characterized in that, in red1_blue2, when red line segment and a blue line segment were overlapping, the intersection point attribute of said crossing line segment comprised that beginning is overlapping or finish overlapping.
10. the method for superimposing lines and surfaces that is applied among the GIS according to claim 3; It is characterized in that; In red2_blue1, two red line segments all join with the blue line segment and when the homonymy of blue line segment, and the intersection point of said crossing line segment does not write down or writes down and its attribute comprises and joining.
11. the method for superimposing lines and surfaces that is applied among the GIS according to claim 3 is characterized in that, in red2_blue1, two red line segments all join with the blue line segment and when the heteropleural of blue line segment, the intersection point attribute of said crossing line segment comprises a little or goes into a little.
12. the method for superimposing lines and surfaces that is applied among the GIS according to claim 3 is characterized in that, in red2_blue1, when a red line segment and blue line segment were overlapping, the intersection point attribute of said crossing line segment comprised that beginning is overlapping or finish overlapping.
13. the method for superimposing lines and surfaces that is applied among the GIS according to claim 3; It is characterized in that; In red2_blue2, when two red line segments and two blue line segments joined and do not have cross reference, the intersection point of said crossing line segment did not write down or writes down and its attribute comprises and joining.
14. the method for superimposing lines and surfaces that is applied among the GIS according to claim 3; It is characterized in that; In red2_blue2, when two red line segments and two blue line segments joined and have cross reference, the intersection point attribute of said crossing line segment comprised a little or goes into a little.
15. the method for superimposing lines and surfaces that is applied among the GIS according to claim 3 is characterized in that, in red2_blue2, when a red line segment and a blue line segment were overlapping, the intersection point attribute of said crossing line segment comprised that beginning is overlapping or finish overlapping.
16. the method for superimposing lines and surfaces that is applied among the GIS according to claim 3 is characterized in that, in red2_blue2, two red line segments and two blue line segments are not when overlapping fully respectively, and the intersection point of said crossing line segment is record not.
17. the method for superimposing lines and surfaces that is applied among the GIS according to claim 3; It is characterized in that; In red2_blue2; Article two, the red line segment overlaps respectively with two blue line segments fully, and the line at two red line segment places is when polygonal limit that two blue line segments belong to overlaps fully, and the intersection point attribute of said crossing line segment comprises overlapping fully.
18. the method for superimposing lines and surfaces that is applied among the GIS according to claim 3; It is characterized in that; In red2_blue2; Article two, the red line segment overlaps respectively with two blue line segments fully, and the line at two red line segment places is when polygonal limit that two blue line segments belong to not exclusively overlaps, and the intersection point of said crossing line segment is record not.
19. the method for superimposing lines and surfaces among the GIS that is applied to according to shown in the claim 1 is characterized in that said step 2) comprise the steps:
Sort said intersection point according to the line under it;
Belonging to intersection point on each bar line according to series arrangement from the origin-to-destination of said line;
Scan all intersection points successively, and, obtain the part of line outside polygon, in polygon and on Polygonal Boundary respectively, accomplish geometric superposition according to the attribute of intersection point.
20. the method for superimposing lines and surfaces among the GIS that is applied to according to shown in the claim 1 is characterized in that said step 3) comprises the steps:
Do not have at said and polygon to choose representative point on the line of intersection point;
Judge representative point and said polygonal relation, and according to representative point in polygon or outside polygon, obtain said and polygon not have the line of intersection point be in polygon or outside polygon, the completion geometric superposition.
CN2008101016177A 2008-03-10 2008-03-10 Method for superimposing lines and surfaces Expired - Fee Related CN101533524B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2008101016177A CN101533524B (en) 2008-03-10 2008-03-10 Method for superimposing lines and surfaces

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2008101016177A CN101533524B (en) 2008-03-10 2008-03-10 Method for superimposing lines and surfaces

Publications (2)

Publication Number Publication Date
CN101533524A CN101533524A (en) 2009-09-16
CN101533524B true CN101533524B (en) 2012-01-18

Family

ID=41104100

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2008101016177A Expired - Fee Related CN101533524B (en) 2008-03-10 2008-03-10 Method for superimposing lines and surfaces

Country Status (1)

Country Link
CN (1) CN101533524B (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5572634A (en) * 1994-10-26 1996-11-05 Silicon Engines, Inc. Method and apparatus for spatial simulation acceleration
CN1192547A (en) * 1996-10-23 1998-09-09 三星电子株式会社 Map data base management method and system therefor

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5572634A (en) * 1994-10-26 1996-11-05 Silicon Engines, Inc. Method and apparatus for spatial simulation acceleration
CN1192547A (en) * 1996-10-23 1998-09-09 三星电子株式会社 Map data base management method and system therefor

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
Ludger Becker et al..Algorithms for Performing Polygonal Map Overlay and Spatial Join on Massive Data Sets.《LNCS》.1999,第1651卷第270页至275页,图2. *
张文艺.GIS缓冲区和叠加分析.《中国优秀硕士学位论文全文数据库》.2007,(第6期),第39页至第42页. *

Also Published As

Publication number Publication date
CN101533524A (en) 2009-09-16

Similar Documents

Publication Publication Date Title
CN103703490B (en) For generation of the equipment of three-dimensional feature data and the method for generation of three-dimensional feature data
CN110689569B (en) Integrated circuit layout field identification and grid subdivision processing method and device
US5125038A (en) Face and edge trim method for an automatic mesh generation system
TWI718612B (en) Method of operating route generator and computing system
CN107092978B (en) Shortest path layered planning method for virtual earth
CN111898331A (en) Random dynamic allocation method for frequency domain simulation calculation tasks of very large scale integrated circuit
CN107329962A (en) Image retrieval data library generating method, the method and device of augmented reality
CN102193998A (en) Arc scanning type construction scheme of triangular irregular network containing edge topological information
CN101533525B (en) Method for analyzing the overlay of point and face
CN103226845A (en) TIN-based earth surface refinement processing method and system
CN108920105A (en) Diagram data distributed storage method and device based on community structure
CN104699791A (en) Lost floating car track path recovery method
US5835095A (en) Visible line processor
CN102799725A (en) Method for determining effective stacking area during off-line stacking for transfer robot
CN101533524B (en) Method for superimposing lines and surfaces
CN102236721B (en) Method for extracting complex window space information in space data engine
US20230274065A1 (en) Using machine learning to produce routes
van Roessel A new approach to plane-sweep overlay: Topological structuring and line-segment classification
CN116089557A (en) Data processing method, device and storage medium
CN113204607B (en) Vector polygon rasterization method for balancing area, topology and shape characteristics
CN113609691A (en) Intersection modeling processing method for intelligent traffic simulation
CN105139435A (en) Boundary unicursal method for processing polygon multiplex inclusion relation
Du et al. A progressive method of simplifying polylines with multi-bends simplification templates
Wagner Path planning algorithms under the link-distance metric
CN114693869B (en) 3D printing entity model generation method based on half-side data structure

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
ASS Succession or assignment of patent right

Owner name: BEIJING ZHONGKE SUANYUAN TECHNOLOGY DEVELOPMENT CO

Free format text: FORMER OWNER: INST. OF COMPUTING TECHNOLOGY, CHINESE ACADEMY OF SCIENCES

Effective date: 20110624

C41 Transfer of patent application or patent right or utility model
COR Change of bibliographic data

Free format text: CORRECT: ADDRESS; FROM: 100080 NO. 6, KEXUEYUAN SOUTH ROAD, ZHONGGUANCUN, HAIDIAN DISTRICT, BEIJING TO: 100190 ROOM 1213, COMPREHENSIVE SCIENTIFIC RESEARCH BUILDING, NO. 6, KEXUEYUAN SOUTH ROAD, ZHONGGUANCUN, HAIDIAN DISTRICT, BEIJING

TA01 Transfer of patent application right

Effective date of registration: 20110624

Address after: 100190 room 1213, comprehensive research building, No. 6 South Road, Zhongguancun Academy of Sciences, Beijing, Haidian District

Applicant after: Beijing Zhongke computer source technology development Co Ltd

Address before: 100080 Haidian District, Zhongguancun Academy of Sciences, South Road, No. 6, No.

Applicant before: Institute of Computing Technology, Chinese Academy of Sciences

ASS Succession or assignment of patent right

Owner name: BEIJING ZHONGKE TONGTU INFORMATION TECHNOLOGY CO.,

Free format text: FORMER OWNER: BEIJING ZHONGKE SUANYUAN TECHNOLOGY DEVELOPMENT CO., LTD.

Effective date: 20110818

C41 Transfer of patent application or patent right or utility model
COR Change of bibliographic data

Free format text: CORRECT: ADDRESS; FROM: 100190 HAIDIAN, BEIJING TO: 100192 HAIDIAN, BEIJING

TA01 Transfer of patent application right

Effective date of registration: 20110818

Address after: 100192, Beijing District, Haidian District science and technology road, 8, science and technology wealth center, block A, 11 North Zone

Applicant after: Beijing Zhongke Tongtu Information Technology Co., Ltd.

Address before: 100190 room 1213, comprehensive research building, No. 6 South Road, Zhongguancun Academy of Sciences, Beijing, Haidian District

Applicant before: Beijing Zhongke computer source technology development Co Ltd

C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20120118

Termination date: 20210310

CF01 Termination of patent right due to non-payment of annual fee