[postgis-tickets] [PostGIS] #3905: Extend ST_SetEffectiveArea so it also works on start/endpoints of polygons

PostGIS trac at osgeo.org
Mon Oct 16 04:27:04 PDT 2017


#3905: Extend ST_SetEffectiveArea so it also works on start/endpoints of polygons
---------------------------------+---------------------------
 Reporter:  tomvantilburg        |      Owner:  pramsey
     Type:  enhancement          |     Status:  new
 Priority:  medium               |  Milestone:  PostGIS 2.4.1
Component:  postgis              |    Version:  2.4.x
 Keywords:  ST_SetEffectiveArea  |
---------------------------------+---------------------------
 ''ST_SetEffectiveArea'' (and hence ''ST_SimplifyVW'') always sets the
 points related to start and endpoint of a polygon to ''dbl_max'' (example
 below). While this is logical for linestrings (it would break your network
 otherwise), it could be implemented better for polygons by reconnecting
 the polygon when start/endpoint are throw out because of a small effective
 area. This would be useful for example when polygons have spikes
 originating from the startpoint that are supposed to be removed by this
 algorithm.
 Not to break existing behaviour or break existing topological nodes this
 should be optional.

 Also see this thread: [https://lists.osgeo.org/pipermail/postgis-
 devel/2017-October/026669.html]

 ----
 Example:

 {{{
 SELECT
  ST_AsTExt(
   (ST_DumpPoints(
    ST_SetEffectiveArea(
     ST_GeometryFromText(
 'POLYGON((
 0 0,
 10 0,
 20 0,
 20 10,
 10 10,
 10 0,
 0 0
 ))'
     )
    ,0.1)
 )).geom)
 }}}


 Result:

 {{{
 "POINT M (0 0 3.40282346638529e+38)"
 "POINT M (20 0 3.40282346638529e+38)"
 "POINT M (20 10 3.40282346638529e+38)"
 "POINT M (10 10 50)"
 "POINT M (10 0 50)"
 "POINT M (0 0 3.40282346638529e+38)"
 }}}

--
Ticket URL: <https://trac.osgeo.org/postgis/ticket/3905>
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