PostGIS 3.7.0dev-r@@SVN_REVISION@@
Loading...
Searching...
No Matches

◆ ST_FlipCoordinates()

Datum ST_FlipCoordinates ( PG_FUNCTION_ARGS  )

Definition at line 3046 of file lwgeom_functions_basic.c.

3047{
3048 GSERIALIZED *in = PG_GETARG_GSERIALIZED_P_COPY(0);
3049 GSERIALIZED *out;
3050 LWGEOM *lwgeom = lwgeom_from_gserialized(in);
3051
3053 out = geometry_serialize(lwgeom);
3054
3055 lwgeom_free(lwgeom);
3056 PG_FREE_IF_COPY(in, 0);
3057
3058 PG_RETURN_POINTER(out);
3059}
LWGEOM * lwgeom_from_gserialized(const GSERIALIZED *g)
Allocate a new LWGEOM from a GSERIALIZED.
@ LWORD_Y
Definition liblwgeom.h:132
@ LWORD_X
Definition liblwgeom.h:131
void lwgeom_free(LWGEOM *geom)
Definition lwgeom.c:1246
void lwgeom_swap_ordinates(LWGEOM *in, LWORD o1, LWORD o2)
Swap ordinate values in every vertex of the geometry.
Definition lwgeom.c:1569

References lwgeom_free(), lwgeom_from_gserialized(), lwgeom_swap_ordinates(), LWORD_X, and LWORD_Y.

Here is the call graph for this function: