[postgis-devel] [PostGIS] #1706: TopoGeo_AddPolygon not adding polygons

PostGIS trac at osgeo.org
Fri Mar 23 10:32:42 PDT 2012


#1706: TopoGeo_AddPolygon not adding polygons
----------------------+-----------------------------------------------------
 Reporter:  pramsey   |       Owner:  strk         
     Type:  defect    |      Status:  new          
 Priority:  medium    |   Milestone:  PostGIS 2.0.0
Component:  topology  |     Version:  trunk        
 Keywords:            |  
----------------------+-----------------------------------------------------

Comment(by strk):

 Oh, I realized TopoGeo_AddPoint, when splitting an edge, is splitting by a
 projected point rather than by the actual given point. I bet that's where
 the precision is going.
 Precision is about these two lines not being the same when I expected them
 to be:
 {{{
 =# with inp as (SELECT
 '01020000000300000000000000000034400000000000002440000000000000244000000000000024400000000000002240FFFFFFFFFFFF2740'::geometry
 as e,
 '01020000000400000000000000000022400000000000002840000000000000244000000000000024400000000000002E40000000000000244000000000000034400000000000002440'::geometry
 as n ) select st_astext(e) as e, st_astext(n) as n, st_equals(e,n),
 st_hausdorffdistance(e,n), st_astext(st_symdifference(e,n)) as sd,
 st_equals(st_snap(n,e,1e-14), e) as snapequals from inp;
 -[ RECORD 1 ]--------+-------------------------------------------
 e                    | LINESTRING(20 10,10 10,9 12)
 n                    | LINESTRING(9 12,10 10,15 10,20 10)
 st_equals            | f
 st_hausdorffdistance | 1.77635683940025e-15
 sd                   | MULTILINESTRING((10 10,9 12),(9 12,10 10))
 snapequals           | t
 }}}

-- 
Ticket URL: <http://trac.osgeo.org/postgis/ticket/1706#comment:12>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.


More information about the postgis-devel mailing list