PostGIS  2.5.7dev-r@@SVN_REVISION@@

◆ linemerge()

Datum linemerge ( PG_FUNCTION_ARGS  )

Definition at line 3029 of file postgis/lwgeom_geos.c.

3030 {
3031  GSERIALIZED *geom1;
3032  GSERIALIZED *result;
3033  LWGEOM *lwgeom1, *lwresult ;
3034 
3035  geom1 = PG_GETARG_GSERIALIZED_P(0);
3036 
3037 
3038  lwgeom1 = lwgeom_from_gserialized(geom1) ;
3039 
3040  lwresult = lwgeom_linemerge(lwgeom1);
3041  result = geometry_serialize(lwresult) ;
3042 
3043  lwgeom_free(lwgeom1) ;
3044  lwgeom_free(lwresult) ;
3045 
3046  PG_FREE_IF_COPY(geom1, 0);
3047 
3048  PG_RETURN_POINTER(result);
3049 }
LWGEOM * lwgeom_from_gserialized(const GSERIALIZED *g)
Allocate a new LWGEOM from a GSERIALIZED.
void lwgeom_free(LWGEOM *geom)
Definition: lwgeom.c:1144
LWGEOM * lwgeom_linemerge(const LWGEOM *geom1)
GSERIALIZED * geometry_serialize(LWGEOM *lwgeom)

References geometry_serialize(), lwgeom_free(), lwgeom_from_gserialized(), and lwgeom_linemerge().

Here is the call graph for this function: