PostGIS 3.7.0dev-r@@SVN_REVISION@@
Loading...
Searching...
No Matches

◆ assvg_curvepoly()

static void assvg_curvepoly ( stringbuffer_t sb,
const LWCURVEPOLY curvepoly,
int  relative,
int  precision 
)
static

in theory this should never happen

Definition at line 406 of file lwout_svg.c.

407{
408 uint32_t i;
409 LWGEOM *tmp;
410
411 for (i = 0; i < curvepoly->nrings; i++)
412 {
413 if (i) stringbuffer_append(sb, " "); /* Space between each ring */
414 tmp = curvepoly->rings[i];
415 switch (tmp->type)
416 {
417 case CIRCSTRINGTYPE:
418 assvg_circstring(sb, (LWCIRCSTRING *)tmp, relative, precision);
419 break;
420
421 case LINETYPE:
422 assvg_line(sb, (LWLINE *)tmp, relative, precision);
423 break;
424
425 case COMPOUNDTYPE:
426 assvg_compound(sb, (LWCOMPOUND *)tmp, relative, precision);
427 break;
428
429 default:
430 break;
431 }
432 if (relative)
433 {
434 stringbuffer_append(sb, " z"); /* SVG closepath */
435 }
436 else
437 {
438 stringbuffer_append(sb, " Z"); /* SVG closepath */
439 }
440 }
441}
static uint8_t precision
Definition cu_in_twkb.c:25
#define COMPOUNDTYPE
Definition liblwgeom.h:110
#define LINETYPE
Definition liblwgeom.h:103
#define CIRCSTRINGTYPE
Definition liblwgeom.h:109
static void assvg_compound(stringbuffer_t *sb, const LWCOMPOUND *icompound, int relative, int precision)
Definition lwout_svg.c:261
static void assvg_line(stringbuffer_t *sb, const LWLINE *line, int relative, int precision)
Definition lwout_svg.c:152
static void assvg_circstring(stringbuffer_t *sb, const LWCIRCSTRING *icurve, int relative, int precision)
Definition lwout_svg.c:253
static void stringbuffer_append(stringbuffer_t *s, const char *a)
Append the specified string to the stringbuffer_t.
LWGEOM ** rings
Definition liblwgeom.h:603
uint32_t nrings
Definition liblwgeom.h:608
uint8_t type
Definition liblwgeom.h:462

References assvg_circstring(), assvg_compound(), assvg_line(), CIRCSTRINGTYPE, COMPOUNDTYPE, LINETYPE, LWCURVEPOLY::nrings, precision, LWCURVEPOLY::rings, stringbuffer_append(), and LWGEOM::type.

Referenced by assvg_geom(), assvg_multisurface(), and lwgeom_to_svg().

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