PostGIS  2.2.7dev-r@@SVN_REVISION@@
Datum LWGEOM_perimeter_poly ( PG_FUNCTION_ARGS  )

Definition at line 315 of file lwgeom_functions_basic.c.

References dumpnode::geom, lwgeom_from_gserialized(), and lwgeom_perimeter().

316 {
317  GSERIALIZED *geom = PG_GETARG_GSERIALIZED_P(0);
318  LWGEOM *lwgeom = lwgeom_from_gserialized(geom);
319  double perimeter = 0.0;
320 
321  perimeter = lwgeom_perimeter(lwgeom);
322  PG_FREE_IF_COPY(geom, 0);
323  PG_RETURN_FLOAT8(perimeter);
324 }
LWGEOM * lwgeom_from_gserialized(const GSERIALIZED *g)
Allocate a new LWGEOM from a GSERIALIZED.
double lwgeom_perimeter(const LWGEOM *geom)
Definition: lwgeom.c:1602
LWGEOM * geom

Here is the call graph for this function: