From: Sandro Santilli Date: Thu, 19 May 2011 20:36:47 +0000 (+0000) Subject: topology.AddEdge: make edge linking self-consistent (each added edge will form a... X-Git-Tag: 2.0.0alpha1~1611 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=c2124080842d2bcb8976e730505df5070b4d7473;p=postgis topology.AddEdge: make edge linking self-consistent (each added edge will form a proper loop) git-svn-id: http://svn.osgeo.org/postgis/trunk@7201 b70326c6-7e19-0410-871a-916f4a2858ee --- diff --git a/topology/sql/populate.sql b/topology/sql/populate.sql index 731f8ffb3..1f1abc26d 100644 --- a/topology/sql/populate.sql +++ b/topology/sql/populate.sql @@ -131,7 +131,7 @@ LANGUAGE 'plpgsql' VOLATILE; -- node or interects with an existing edge on anything but endnodes. -- -- The newly added edge has "universe" face on both sides --- and links to itself. +-- and links to itself as per next left/right edge. -- Calling code is expected to do further linking. -- -- @@ -276,7 +276,7 @@ BEGIN || ')) ,' -- next_left_edge - || edgeid ||',' + || -edgeid ||',' -- next_right_edge || edgeid ||',' diff --git a/topology/test/regress/addedge_expected b/topology/test/regress/addedge_expected index 4c6445ba0..39be89d6b 100644 --- a/topology/test/regress/addedge_expected +++ b/topology/test/regress/addedge_expected @@ -21,14 +21,14 @@ ERROR: Edge intersects (not on endpoints) with existing edge 7 at or near point ERROR: Edge intersects (not on endpoints) with existing edge 7 at or near point POINT(8 10) ERROR: Edge intersects (not on endpoints) with existing edge 7 at or near point POINT(10 12) #770-1*|7 -1|0|0|1|1|LINESTRING(0 0,8 0) -2|0|0|2|2|LINESTRING(8 0,8 10) -3|0|0|3|3|LINESTRING(0 0,0 10) -4|0|0|4|4|LINESTRING(8 10,0 10) -5|0|0|5|5|LINESTRING(8 -10,0 -10) -6|0|0|6|6|LINESTRING(8 -10,4 -20,0 -10) -7|0|0|7|7|LINESTRING(8 10,10 10,10 12,8 10) -8|0|0|8|8|LINESTRING(8 10,9 8,10 9,8 10) +1|0|0|-1|1|LINESTRING(0 0,8 0) +2|0|0|-2|2|LINESTRING(8 0,8 10) +3|0|0|-3|3|LINESTRING(0 0,0 10) +4|0|0|-4|4|LINESTRING(8 10,0 10) +5|0|0|-5|5|LINESTRING(8 -10,0 -10) +6|0|0|-6|6|LINESTRING(8 -10,4 -20,0 -10) +7|0|0|-7|7|LINESTRING(8 10,10 10,10 12,8 10) +8|0|0|-8|8|LINESTRING(8 10,9 8,10 9,8 10) Topology 'tt' dropped t MiX|1