[PostGIS] #5867: Add documentation for Straight Skeleton with Point Touching Rings
PostGIS
trac at osgeo.org
Thu Mar 20 08:28:31 PDT 2025
#5867: Add documentation for Straight Skeleton with Point Touching Rings
--------------------------+---------------------------
Reporter: gravitystorm | Owner: pramsey
Type: enhancement | Status: new
Priority: medium | Milestone: PostGIS 3.5.3
Component: postgis | Version: 3.4.x
Keywords: |
--------------------------+---------------------------
I have recently found that CG_StraightSkeleton (and
CG_ApproximateMedialAxis) will throw an error for certain valid
geometries, specifically valid polygons with a point touching inner ring.
{{{
gis=# select st_isvalid(ST_GeomFromText('POLYGON((0 0, 3 0, 3 3, 0 3, 0
0),(0 0, 1 2, 2 1, 0 0))'));
st_isvalid
------------
t
(1 row)
gis=# select st_straightskeleton(ST_GeomFromText('POLYGON((0 0, 3 0, 3 3,
0 3, 0 0), (0 0, 1 2, 2 1, 0 0))'));
NOTICE: During straight_skeleton(A) :
NOTICE: with A: POLYGON((0/1 0/1,3/1 0/1,3/1 3/1,0/1 3/1,0/1 0/1),(0/1
0/1,1/1 2/1,2/1 1/1,0/1 0/1))
ERROR: straight skeleton of Polygon with point touching rings is not
implemented.
}}}
I think it would be helpful to mention this in the documentation for these
functions.
This is in order to raise awareness of the limitation when a developer
(like me!) is implementing the query, rather than it failing unexpectedly
some time later with production data.
--
Ticket URL: <https://trac.osgeo.org/postgis/ticket/5867>
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