PostGIS  2.5.0beta2dev-r@@SVN_REVISION@@

◆ sfcgal_from_ewkt()

Datum sfcgal_from_ewkt ( PG_FUNCTION_ARGS  )

Definition at line 142 of file postgis/lwgeom_sfcgal.c.

References PG_FUNCTION_INFO_V1(), sfcgal_area(), sfcgal_postgis_init(), SFCGALPreparedGeometry2POSTGIS(), and text_to_cstring().

Referenced by SFCGALPreparedGeometry2POSTGIS().

143 {
144  GSERIALIZED* result;
145  sfcgal_prepared_geometry_t* g;
146  text *wkttext = PG_GETARG_TEXT_P(0);
147  char *cstring = text_to_cstring(wkttext);
148 
150 
151  g = sfcgal_io_read_ewkt( cstring, strlen(cstring) );
152 
153  result = SFCGALPreparedGeometry2POSTGIS( g, 0 );
154  sfcgal_prepared_geometry_delete( g );
155  PG_RETURN_POINTER(result);
156 }
GSERIALIZED * SFCGALPreparedGeometry2POSTGIS(const sfcgal_prepared_geometry_t *geom, int force3D)
char * text_to_cstring(const text *textptr)
void sfcgal_postgis_init(void)
Here is the call graph for this function:
Here is the caller graph for this function: