PostGIS  3.3.9dev-r@@SVN_REVISION@@

◆ assvg_collection_size()

static size_t assvg_collection_size ( const LWCOLLECTION col,
int  relative,
int  precision 
)
static

Collection Geometry.

Definition at line 395 of file lwout_svg.c.

396 {
397  uint32_t i = 0;
398  size_t size=0;
399  const LWGEOM *subgeom;
400 
401  for (i=0; i<col->ngeoms; i++)
402  {
403  subgeom = col->geoms[i];
404  size += assvg_geom_size(subgeom, relative, precision);
405  }
406 
407  if ( i ) /* We have some geometries, so add space for delimiters. */
408  size += sizeof(";") * --i;
409 
410  if (size == 0) size++; /* GEOMETRYCOLLECTION EMPTY, space for null terminator */
411 
412  return size;
413 }
static uint8_t precision
Definition: cu_in_twkb.c:25
static size_t assvg_geom_size(const LWGEOM *geom, int relative, int precision)
Definition: lwout_svg.c:488
uint32_t ngeoms
Definition: liblwgeom.h:595
LWGEOM ** geoms
Definition: liblwgeom.h:590

References assvg_geom_size(), LWCOLLECTION::geoms, LWCOLLECTION::ngeoms, and precision.

Referenced by assvg_collection().

Here is the call graph for this function:
Here is the caller graph for this function: