660 geom = PG_GETARG_GSERIALIZED_P(0);
663 lwpgerror(
"Argument to ST_Z() must be a point");
676 PG_FREE_IF_COPY(geom, 0);
678 PG_RETURN_FLOAT8(p.
z);
int gserialized_has_z(const GSERIALIZED *gser)
Check if a GSERIALIZED has a Z ordinate.
LWGEOM * lwgeom_from_gserialized(const GSERIALIZED *g)
Allocate a new LWGEOM from a GSERIALIZED.
uint32_t gserialized_get_type(const GSERIALIZED *s)
Extract the geometry type from the serialized form (it hides in the anonymous data area,...
#define POINTTYPE
LWTYPE numbers, used internally by PostGIS.
LWPOINT * lwgeom_as_lwpoint(const LWGEOM *lwgeom)
int getPoint3dz_p(const POINTARRAY *pa, uint32_t n, POINT3DZ *point)
int lwgeom_is_empty(const LWGEOM *geom)
Return true or false depending on whether a geometry is an "empty" geometry (no vertices members)