[geos-devel] Dimension of EMPTY geoms
Mateusz Loskot
mateusz at loskot.net
Mon Dec 4 09:18:54 EST 2006
strk at refractions.net wrote:
> See bug
> http://postgis.refractions.net/bugs/bug.php?op=show&bugid=135&pos=5
>
> Questions are:
>
> 1) Should EMPTY geometries of *any* kind return 0 from getDimension()
> ?
AFAIK OGC SFS does say nothing about how to report dimension of empty
geometry.
MySQL spatial extensions report dim of empty geometry with value -1
http://dev.mysql.com/doc/refman/5.0/en/gis-class-geometry.html
OGC SFS reserves values 0, 1, and 2 for dimensions of non-empty
geometry, so I'd suggest to use negative value.
> 2) Should CAPI's GEOSCoordSeq_create() raise an error if requested to
> create anything but a 3d geom ? (the only one supported)
I think that if it can detect unsupported request, then the fact
should be reported with an error code.
Cheers
--
Mateusz Loskot
http://mateusz.loskot.net
More information about the geos-devel
mailing list