[PostGIS] #5639: ST_DFullyWithin fails when dealing with LINESTRING and POLYGON

PostGIS trac at osgeo.org
Tue Jan 23 12:46:42 PST 2024


#5639: ST_DFullyWithin fails when dealing with LINESTRING and POLYGON
----------------------+---------------------------
  Reporter:  Wenjing  |      Owner:  pramsey
      Type:  defect   |     Status:  new
  Priority:  medium   |  Milestone:  PostGIS 3.4.2
 Component:  postgis  |    Version:  3.4.x
Resolution:           |   Keywords:
----------------------+---------------------------
Comment (by pramsey):

 OK, so back to the actual problem, which seems in this case confined to
 ST_DFullyWithin.
 {{{
 SELECT ST_MaxDistance(
   'LINESTRING(0 0, 0 1, 1 0, 0 0)'::geometry,
   'POLYGON((0 0, 0 1, 1 0, 0 0))'::geometry);

    st_maxdistance
 --------------------
  1.4142135623730951

 SELECT ST_DFullyWithin(
   'LINESTRING(0 0, 0 1, 1 0, 0 0)'::geometry,
   'POLYGON((0 0, 0 1, 1 0, 0 0))'::geometry,
   100);

  st_dfullywithin
 -----------------
  f
 }}}
 So the maximum distance between vertices in those two rings is indeed
 sqrt(2). But that... is way less than 100, so something is odd with the
 ST_DFullyWithin test.
-- 
Ticket URL: <https://trac.osgeo.org/postgis/ticket/5639#comment:13>
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-tickets mailing list