PostGIS  2.2.7dev-r@@SVN_REVISION@@
postgis/lwgeom_geos.h
Go to the documentation of this file.
1 /**********************************************************************
2  *
3  * PostGIS - Spatial Types for PostgreSQL
4  * http://postgis.net
5  *
6  * Copyright 2008 Paul Ramsey <pramsey@cleverelephant.ca>
7  *
8  * This is free software; you can redistribute and/or modify it under
9  * the terms of the GNU General Public Licence. See the COPYING file.
10  *
11  **********************************************************************/
12 
13 #ifndef LWGEOM_GEOS_H_
14 #define LWGEOM_GEOS_H_ 1
15 
16 #include "../liblwgeom/lwgeom_geos.h" /* for GEOSGeom */
17 #include "liblwgeom.h" /* for GSERIALIZED */
18 #include "utils/array.h" /* for ArrayType */
19 
20 /*
21 ** Public prototypes for GEOS utility functions.
22 */
23 
24 GSERIALIZED *GEOS2POSTGIS(GEOSGeom geom, char want3d);
25 GEOSGeometry * POSTGIS2GEOS(GSERIALIZED *g);
26 GEOSGeometry** ARRAY2GEOS(ArrayType* array, uint32_t nelems, int* is3d, int* srid);
27 LWGEOM** ARRAY2LWGEOM(ArrayType* array, uint32_t nelems, int* is3d, int* srid);
28 
29 Datum geos_intersects(PG_FUNCTION_ARGS);
30 Datum geos_intersection(PG_FUNCTION_ARGS);
31 Datum geos_difference(PG_FUNCTION_ARGS);
32 Datum geos_geomunion(PG_FUNCTION_ARGS);
33 Datum LWGEOM_area_polygon(PG_FUNCTION_ARGS);
34 Datum LWGEOM_mindistance2d(PG_FUNCTION_ARGS);
35 Datum LWGEOM_mindistance3d(PG_FUNCTION_ARGS);
36 
38 uint32_t array_nelems_not_null(ArrayType* array);
39 
40 #endif /* LWGEOM_GEOS_H_ */
GEOSGeometry ** ARRAY2GEOS(ArrayType *array, uint32_t nelems, int *is3d, int *srid)
uint32_t array_nelems_not_null(ArrayType *array)
GEOSGeometry * POSTGIS2GEOS(GSERIALIZED *g)
LWGEOM ** ARRAY2LWGEOM(ArrayType *array, uint32_t nelems, int *is3d, int *srid)
Datum LWGEOM_mindistance2d(PG_FUNCTION_ARGS)
Datum geos_geomunion(PG_FUNCTION_ARGS)
const GEOSGeometry * geom
Datum LWGEOM_mindistance3d(PG_FUNCTION_ARGS)
Datum LWGEOM_area_polygon(PG_FUNCTION_ARGS)
Datum geos_intersects(PG_FUNCTION_ARGS)
GSERIALIZED * GEOS2POSTGIS(GEOSGeom geom, char want3d)
Datum geos_difference(PG_FUNCTION_ARGS)
Datum geos_intersection(PG_FUNCTION_ARGS)
This library is the generic geometry handling section of PostGIS.
void errorIfGeometryCollection(GSERIALIZED *g1, GSERIALIZED *g2)
Throws an ereport ERROR if either geometry is a COLLECTIONTYPE.