When features are snapped or sometimes they are just this way, they are very close to the geodetic bounds but slightly over.
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 3252 of file lwgeodetic.c.
3253{
3255 uint32_t i = 0;
3257
3258 assert(geom);
3259
3260
3263
3265
3268
3271
3273 {
3275 for ( i = 0; i < poly->
nrings; i++ )
3276 {
3278 rv = (rv ==
LW_TRUE ? rv : n);
3279 }
3280 return rv;
3281 }
3282
3285
3287 {
3289
3290 for ( i = 0; i < col->
ngeoms; i++ )
3291 {
3293 rv = (rv ==
LW_TRUE ? rv : n);
3294 }
3295 return rv;
3296 }
3297
3299 return rv;
3300}
const char * lwtype_name(uint8_t type)
Return the type name string associated with a type number (e.g.
int lwtype_is_collection(uint8_t type)
Determine whether a type number is a collection or not.
#define POINTTYPE
LWTYPE numbers, used internally by PostGIS.
#define LW_TRUE
Return types for functions with status returns.
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...
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...
void void lwerror(const char *fmt,...) __attribute__((format(printf
Write a notice out to the error handler.
static int lwgeom_is_empty(const LWGEOM *geom)
Return true or false depending on whether a geometry is an "empty" geometry (no vertices members)
References LWCOLLECTION::geoms, LINETYPE, LW_FALSE, LW_TRUE, lwerror(), lwgeom_is_empty(), lwgeom_nudge_geodetic(), lwtype_is_collection(), lwtype_name(), LWCOLLECTION::ngeoms, LWPOLY::nrings, POINTTYPE, POLYGONTYPE, ptarray_nudge_geodetic(), LWPOLY::rings, TRIANGLETYPE, and LWGEOM::type.
Referenced by geography_from_geometry(), gserialized_geography_from_lwgeom(), and lwgeom_nudge_geodetic().