Gently move coordinates of LWGEOM if they are close enough into geodetic range.
Gently move coordinates of LWGEOM if they are close enough into geodetic range.
This routine nudges those points, and only those points, back over to the bounds. http://trac.osgeo.org/postgis/ticket/1292
Definition at line 3388 of file lwgeodetic.c.
References LWCOLLECTION::geoms, LINETYPE, LW_FALSE, LW_TRUE, lwerror(), lwgeom_is_empty(), lwtype_is_collection(), lwtype_name(), LWCOLLECTION::ngeoms, LWPOLY::nrings, POINTTYPE, POLYGONTYPE, ptarray_nudge_geodetic(), LWPOLY::rings, TRIANGLETYPE, ovdump::type, and LWGEOM::type.
Referenced by geography_from_geometry(), and gserialized_geography_from_lwgeom().
3411 for ( i = 0; i < poly->
nrings; i++ )
3414 rv = (rv ==
LW_TRUE ? rv : n);
3426 for ( i = 0; i < col->
ngeoms; i++ )
3429 rv = (rv ==
LW_TRUE ? rv : n);
static int ptarray_nudge_geodetic(POINTARRAY *pa)
When features are snapped or sometimes they are just this way, they are very close to the geodetic bo...
const char * lwtype_name(uint8_t type)
Return the type name string associated with a type number (e.g.
#define LW_TRUE
Return types for functions with status returns.
int lwtype_is_collection(uint8_t type)
Determine whether a type number is a collection or not.
int lwgeom_nudge_geodetic(LWGEOM *geom)
When features are snapped or sometimes they are just this way, they are very close to the geodetic bo...
#define POINTTYPE
LWTYPE numbers, used internally by PostGIS.
int lwgeom_is_empty(const LWGEOM *geom)
Return true or false depending on whether a geometry is an "empty" geometry (no vertices members) ...
void lwerror(const char *fmt,...)
Write a notice out to the error handler.