Definition at line 121 of file lwgeom_wrapx.c.
References COLLECTIONTYPE, LWCOLLECTION::geoms, lwalloc(), lwcollection_construct(), LWDEBUGF, lwerror(), lwfree(), lwgeom_free(), lwgeom_wrapx(), lwnotice(), MULTITYPE, LWCOLLECTION::ngeoms, LWCOLLECTION::srid, ovdump::type, and LWCOLLECTION::type.
Referenced by lwgeom_split_wrapx(), and lwgeom_wrapx().
126 int outtype = lwcoll_in->
type;
131 lwerror(
"Out of virtual memory");
135 for (i=0; i<lwcoll_in->
ngeoms; ++i)
137 LWDEBUGF(3,
"Wrapping collection element %d", i);
140 if ( ! wrap_geoms[i] ) {
141 lwnotice(
"Error wrapping geometry, cleaning up");
143 lwnotice(
"cleaning geometry %d (%p)", i, wrap_geoms[i]);
160 lwcoll_in->
ngeoms, wrap_geoms);
LWCOLLECTION * lwcollection_construct(uint8_t type, int srid, GBOX *bbox, uint32_t ngeoms, LWGEOM **geoms)
void lwnotice(const char *fmt,...)
Write a notice out to the notice handler.
void lwgeom_free(LWGEOM *geom)
LWGEOM * lwgeom_wrapx(const LWGEOM *lwgeom_in, double cutx, double amount)
wrap geometry on given cut x value
uint8_t MULTITYPE[NUMTYPES]
Look-up for the correct MULTI* type promotion for singleton types.
void * lwalloc(size_t size)
#define LWDEBUGF(level, msg,...)
void lwerror(const char *fmt,...)
Write a notice out to the error handler.