[postgis-tickets] [PostGIS] #4211: ST_Subdivide() on geometries with rings

PostGIS trac at osgeo.org
Mon Oct 22 00:57:01 PDT 2018


#4211: ST_Subdivide() on geometries with rings
--------------------------+---------------------------
 Reporter:  morena        |      Owner:  pramsey
     Type:  defect        |     Status:  new
 Priority:  medium        |  Milestone:  PostGIS 2.5.1
Component:  postgis       |    Version:  2.5.x
 Keywords:  ST_Subdivide  |
--------------------------+---------------------------
 The ST_Subdivide() function on PostGIS 2.5.0 yields incorrect results for
 geometries (POLYGON) with rings (wholes).

 To reproduce the issue:
 {{{
 DROP TABLE IF EXISTS test_geom;
 CREATE TABLE test_geom AS
 SELECT ST_GeomFromText('MULTIPOLYGON(((-88.2059 41.7325,-88.2060
 41.7244,-88.1959 41.7241,-88.1959 41.7326,-88.2059 41.7325),(-88.1997
 41.7289,-88.1996 41.7285,-88.1990 41.7285,-88.1990 41.7289,-88.1997
 41.7289)))',4326) AS geom;

 DROP TABLE IF EXISTS test_geom_result;
 CREATE TABLE test_geom_result AS
 SELECT ST_Subdivide(geom) AS geom FROM test_geom;
 }}}

 Attached are the previews of the above.

 View of test geometry (on either PostGIS 2.4.4 or PostGIS 2.5.0):
 [[Image(test_geom.png)]]

 View of result on PostGIS 2.4.4:
 [[Image(postgis_2.4.4_test_geom_result.png)]]

 View of result on PostGIS 2.5.0:
 [[Image(postgis_2.5.0_test_geom_result.png)]]

 The two outputs were tested on following setup:
 PostGIS 2.4.4
 {{{
 SELECT PostGIS_Full_Version();
 POSTGIS="2.4.4 r16526" PGSQL="100" GEOS="3.7.0dev-CAPI-1.11.0 r"
 PROJ="Rel. 4.9.3, 15 August 2016" GDAL="GDAL 2.1.2, released 2016/10/24"
 LIBXML="2.9.4" LIBJSON="0.12.1" RASTER
 }}}

 PostGIS 2.5.0
 {{{
 SELECT PostGIS_Full_Version();
 POSTGIS="2.5.0 r16836" [EXTENSION] PGSQL="110" GEOS="3.7.0-CAPI-1.11.0
 673b9939" PROJ="Rel. 4.9.3, 15 August 2016" GDAL="GDAL 2.3.2, released
 2018/09/21" LIBXML="2.9.4" LIBJSON="0.12.1" RASTER
 }}}

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