Definition at line 489 of file lwout_geojson.c.
495 ptr += sprintf(ptr,
"{\"type\":\"MultiPolygon\",");
498 ptr += sprintf(ptr,
"\"coordinates\":[");
499 for (i=0; i<mpoly->
ngeoms; i++)
501 if (i) ptr += sprintf(ptr,
",");
502 ptr += sprintf(ptr,
"[");
503 poly = mpoly->
geoms[i];
504 for (j=0 ; j < poly->
nrings ; j++)
506 if (j) ptr += sprintf(ptr,
",");
507 ptr += sprintf(ptr,
"[");
509 ptr += sprintf(ptr,
"]");
511 ptr += sprintf(ptr,
"]");
513 ptr += sprintf(ptr,
"]}");
515 return (ptr - output);
#define FLAGS_GET_Z(flags)
Macros for manipulating the 'flags' byte.
static size_t pointArray_to_geojson(POINTARRAY *pa, char *buf, int precision)
static size_t asgeojson_srs_buf(char *output, char *srs)
static size_t asgeojson_bbox_buf(char *output, GBOX *bbox, int hasz, int precision)
References asgeojson_bbox_buf(), asgeojson_srs_buf(), LWMPOLY::flags, FLAGS_GET_Z, LWMPOLY::geoms, LWMPOLY::ngeoms, LWPOLY::nrings, pointArray_to_geojson(), precision, and LWPOLY::rings.
Referenced by asgeojson_geom_buf(), and asgeojson_multipolygon().