PostGIS  2.4.9dev-r@@SVN_REVISION@@

◆ asx3d3_poly_buf()

static size_t asx3d3_poly_buf ( const LWPOLY poly,
char *  srs,
char *  output,
int  precision,
int  opts,
int  is_patch,
const char *  defid 
)
static

Compute the X3D coordinates of the polygon.

Definition at line 339 of file lwout_x3d.c.

References LWPOLY::nrings, pointArray_toX3D3(), and LWPOLY::rings.

Referenced by asx3d3_collection_buf(), asx3d3_multi_buf(), and asx3d3_psurface_buf().

340 {
341  int i;
342  char *ptr=output;
343 
344  ptr += pointArray_toX3D3(poly->rings[0], ptr, precision, opts, 1);
345  for (i=1; i<poly->nrings; i++)
346  {
347  ptr += sprintf(ptr, " "); /* inner ring points start */
348  ptr += pointArray_toX3D3(poly->rings[i], ptr, precision, opts,1);
349  }
350  return (ptr-output);
351 }
POINTARRAY ** rings
Definition: liblwgeom.h:457
uint8_t precision
Definition: cu_in_twkb.c:25
int nrings
Definition: liblwgeom.h:455
opts
Definition: ovdump.py:44
static size_t pointArray_toX3D3(POINTARRAY *pa, char *buf, int precision, int opts, int is_closed)
In X3D3, coordinates are separated by a space separator.
Definition: lwout_x3d.c:840
Here is the call graph for this function:
Here is the caller graph for this function: