PostGIS  2.5.7dev-r@@SVN_REVISION@@
liblwgeom/lwgeom_geos.c File Reference
#include "lwgeom_geos.h"
#include "liblwgeom.h"
#include "liblwgeom_internal.h"
#include "lwgeom_log.h"
#include <stdarg.h>
#include <stdlib.h>
#include <time.h>
Include dependency graph for liblwgeom/lwgeom_geos.c:

Go to the source code of this file.

Macros

#define AUTOFIX   LW_TRUE
 
#define LWGEOM_GEOS_ERRMSG_MAXSIZE   256
 
#define GEOS_FREE(...)
 
#define GEOS_FAIL()
 
#define GEOS_FAIL_DEBUG()
 
#define GEOS_FREE_AND_FAIL(...)
 
#define GEOS_FREE_AND_FAIL_DEBUG(...)
 
#define RESULT_SRID(...)    (get_result_srid((sizeof((const void*[]){__VA_ARGS__})/sizeof(void*)), __func__, __VA_ARGS__))
 

Functions

LWTINlwtin_from_geos (const GEOSGeometry *geom, uint8_t want3d)
 
void lwgeom_geos_error (const char *fmt,...)
 
static void geos_destroy (size_t count,...)
 
POINTARRAYptarray_from_GEOSCoordSeq (const GEOSCoordSequence *cs, uint8_t want3d)
 
LWGEOMGEOS2LWGEOM (const GEOSGeometry *geom, uint8_t want3d)
 
GEOSCoordSeq ptarray_to_GEOSCoordSeq (const POINTARRAY *, uint8_t fix_ring)
 
static GEOSGeometry * ptarray_to_GEOSLinearRing (const POINTARRAY *pa, uint8_t autofix)
 
GEOSGeometry * GBOX2GEOS (const GBOX *box)
 
GEOSGeometry * LWGEOM2GEOS (const LWGEOM *lwgeom, uint8_t autofix)
 
GEOSGeometry * make_geos_point (double x, double y)
 
GEOSGeometry * make_geos_segment (double x1, double y1, double x2, double y2)
 
const char * lwgeom_geos_version ()
 Return GEOS version string (not to be freed) More...
 
static int32_t get_result_srid (size_t count, const char *funcname,...)
 
LWGEOMlwgeom_normalize (const LWGEOM *geom)
 
LWGEOMlwgeom_intersection (const LWGEOM *geom1, const LWGEOM *geom2)
 
LWGEOMlwgeom_linemerge (const LWGEOM *geom)
 
LWGEOMlwgeom_unaryunion (const LWGEOM *geom)
 
LWGEOMlwgeom_difference (const LWGEOM *geom1, const LWGEOM *geom2)
 
LWGEOMlwgeom_symdifference (const LWGEOM *geom1, const LWGEOM *geom2)
 
LWGEOMlwgeom_centroid (const LWGEOM *geom)
 
LWGEOMlwgeom_pointonsurface (const LWGEOM *geom)
 
LWGEOMlwgeom_union (const LWGEOM *geom1, const LWGEOM *geom2)
 
LWGEOMlwgeom_clip_by_rect (const LWGEOM *geom1, double x1, double y1, double x2, double y2)
 
LWGEOMlwgeom_buildarea (const LWGEOM *geom)
 Take a geometry and return an areal geometry (Polygon or MultiPolygon). More...
 
int lwgeom_is_simple (const LWGEOM *geom)
 
LWGEOMlwgeom_geos_noop (const LWGEOM *geom)
 Convert an LWGEOM to a GEOS Geometry and convert back – for debug only. More...
 
LWGEOMlwgeom_snap (const LWGEOM *geom1, const LWGEOM *geom2, double tolerance)
 Snap vertices and segments of a geometry to another using a given tolerance. More...
 
LWGEOMlwgeom_sharedpaths (const LWGEOM *geom1, const LWGEOM *geom2)
 
static LWGEOMlwline_offsetcurve (const LWLINE *lwline, double size, int quadsegs, int joinStyle, double mitreLimit)
 
static LWGEOMlwcollection_offsetcurve (const LWCOLLECTION *col, double size, int quadsegs, int joinStyle, double mitreLimit)
 
LWGEOMlwgeom_offsetcurve (const LWGEOM *geom, double size, int quadsegs, int joinStyle, double mitreLimit)
 
LWMPOINTlwpoly_to_points (const LWPOLY *lwpoly, uint32_t npoints)
 
LWMPOINTlwmpoly_to_points (const LWMPOLY *lwmpoly, uint32_t npoints)
 
LWMPOINTlwgeom_to_points (const LWGEOM *lwgeom, uint32_t npoints)
 
LWGEOMlwgeom_delaunay_triangulation (const LWGEOM *geom, double tolerance, int32_t output)
 Take vertices of a geometry and build a delaunay triangulation on them. More...
 
static GEOSCoordSequence * lwgeom_get_geos_coordseq_2d (const LWGEOM *g, uint32_t num_points)
 
LWGEOMlwgeom_voronoi_diagram (const LWGEOM *g, const GBOX *env, double tolerance, int output_edges)
 Take vertices of a geometry and build the Voronoi diagram. More...
 

Variables

char lwgeom_geos_errmsg [LWGEOM_GEOS_ERRMSG_MAXSIZE]