798 GEOSGeometry *g1, *g2, *g3;
812 srid = (int)(geom1->
srid);
829 GEOSGeom_destroy(g1);
834 g3 = GEOSDifference(g1,g2);
838 GEOSGeom_destroy(g1);
839 GEOSGeom_destroy(g2);
844 LWDEBUGF(3,
"result: %s", GEOSGeomToWKT(g3) ) ;
846 GEOSSetSRID(g3, srid);
852 GEOSGeom_destroy(g1);
853 GEOSGeom_destroy(g2);
854 GEOSGeom_destroy(g3);
855 lwerror(
"Error performing difference: GEOS2LWGEOM: %s",
860 GEOSGeom_destroy(g1);
861 GEOSGeom_destroy(g2);
862 GEOSGeom_destroy(g3);
void lwnotice(const char *fmt,...)
Write a notice out to the notice handler.
char lwgeom_geos_errmsg[LWGEOM_GEOS_ERRMSG_MAXSIZE]
LWGEOM * lwgeom_clone_deep(const LWGEOM *lwgeom)
Deep clone an LWGEOM, everything is copied.
void error_if_srid_mismatch(int srid1, int srid2)
void lwgeom_geos_error(const char *fmt,...)
#define FLAGS_GET_Z(flags)
Macros for manipulating the 'flags' byte.
GEOSGeometry * LWGEOM2GEOS(const LWGEOM *lwgeom, int autofix)
LWGEOM * GEOS2LWGEOM(const GEOSGeometry *geom, char want3d)
int lwgeom_is_empty(const LWGEOM *geom)
Return true or false depending on whether a geometry is an "empty" geometry (no vertices members) ...
#define LWDEBUGF(level, msg,...)
void lwerror(const char *fmt,...)
Write a notice out to the error handler.