PostGIS  3.3.9dev-r@@SVN_REVISION@@

◆ asgml2_poly()

static lwvarlena_t * asgml2_poly ( const LWPOLY poly,
const char *  srs,
int  precision,
const char *  prefix 
)
static

Definition at line 436 of file lwout_gml.c.

437 {
438  int size = asgml2_poly_size(poly, srs, precision, prefix);
439  lwvarlena_t *output = lwalloc(LWVARHDRSZ + size);
440  size = asgml2_poly_buf(poly, srs, output->data, precision, prefix);
441  LWSIZE_SET(output->size, size + LWVARHDRSZ);
442  return output;
443 }
static uint8_t precision
Definition: cu_in_twkb.c:25
#define LWVARHDRSZ
Definition: liblwgeom.h:326
#define LWSIZE_SET(varsize, len)
Definition: liblwgeom.h:340
void * lwalloc(size_t size)
Definition: lwutil.c:227
static size_t asgml2_poly_buf(const LWPOLY *poly, const char *srs, char *output, int precision, const char *prefix)
Definition: lwout_gml.c:406
static size_t asgml2_poly_size(const LWPOLY *poly, const char *srs, int precision, const char *prefix)
Definition: lwout_gml.c:386
uint32_t size
Definition: liblwgeom.h:322
char data[]
Definition: liblwgeom.h:323

References asgml2_poly_buf(), asgml2_poly_size(), lwvarlena_t::data, lwalloc(), LWSIZE_SET, LWVARHDRSZ, precision, and lwvarlena_t::size.

Referenced by lwgeom_to_gml2().

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