Convert a PostGIS pointarray to SFCGAL structure.
268 int is_3d, is_measured;
284 sfcgal_geometry_t *line = sfcgal_linestring_create();
285 for (i = 0; i < pa->
npoints; i++)
288 sfcgal_linestring_add_point(
296 sfcgal_geometry_t *triangle = sfcgal_triangle_create();
297 for (i = 0; i < 3; i++)
300 sfcgal_geometry_t *vertex =
304 sfcgal_triangle_set_vertex(triangle, i, vertex);
305 sfcgal_geometry_delete(vertex);
312 lwerror(
"ptarray_to_SFCGAL: Unknown Type");
#define POINTTYPE
LWTYPE numbers, used internally by PostGIS.
#define FLAGS_GET_Z(flags)
#define FLAGS_GET_M(flags)
int getPoint4d_p(const POINTARRAY *pa, uint32_t n, POINT4D *point)
void void lwerror(const char *fmt,...) __attribute__((format(printf
Write a notice out to the error handler.
static sfcgal_geometry_t * create_sfcgal_point_by_dimensions(double x, double y, double z, double m, int is_3d, int is_measured)
Create a SFCGAL point based on dimensional flags (XY, XYZ, XYM, XYZM).