mirror of
https://git.osgeo.org/gitea/postgis/postgis
synced 2024-10-25 09:32:46 +00:00
b2ea45f8d6
git-svn-id: http://svn.osgeo.org/postgis/trunk@955 b70326c6-7e19-0410-871a-916f4a2858ee
42 lines
1.4 KiB
C
42 lines
1.4 KiB
C
/*****************************************************************
|
|
* MEMORY MANAGEMENT
|
|
****************************************************************/
|
|
void *lwalloc(size_t size);
|
|
void *lwrealloc(void *mem, size_t size);
|
|
void lwfree(void *mem);
|
|
|
|
/*****************************************************************
|
|
* POINT
|
|
****************************************************************/
|
|
|
|
typedef struct { double x; double y; } POINT2D;
|
|
typedef struct { double x; double y; double m; } POINT3DM;
|
|
typedef struct { double x; double y; double z; } POINT3DZ;
|
|
typedef struct { double x; double y; double z; double m; } POINT4D;
|
|
|
|
/*****************************************************************
|
|
* POINTARRAY
|
|
****************************************************************/
|
|
|
|
typedef struct POINTARRAY_T *POINTARRAY;
|
|
|
|
// Constructs a POINTARRAY copying given 2d points
|
|
POINTARRAY ptarray_construct2d(unsigned int npoints, const POINT2D *pts);
|
|
|
|
/*****************************************************************
|
|
* LWGEOM
|
|
****************************************************************/
|
|
|
|
typedef struct LWGEOM_T *LWGEOM;
|
|
|
|
// Conversions
|
|
extern char *lwgeom_to_wkt(LWGEOM lwgeom);
|
|
|
|
// Construction
|
|
extern LWGEOM lwpoint_construct(int SRID, char wantbbox, POINTARRAY pa);
|
|
extern LWGEOM lwline_construct(int SRID, char wantbbox, POINTARRAY pa);
|
|
|
|
// Spatial functions
|
|
extern void lwgeom_reverse(LWGEOM lwgeom);
|
|
extern void lwgeom_forceRHR(LWGEOM lwgeom);
|