PostGIS  2.3.7dev-r@@SVN_REVISION@@
static size_t gserialized_from_lwpoint_size ( const LWPOINT point)
static

Definition at line 432 of file g_serialized.c.

References LWPOINT::flags, FLAGS_NDIMS, LWDEBUGF, POINTARRAY::npoints, and LWPOINT::point.

Referenced by gserialized_from_any_size().

433 {
434  size_t size = 4; /* Type number. */
435 
436  assert(point);
437 
438  size += 4; /* Number of points (one or zero (empty)). */
439  size += point->point->npoints * FLAGS_NDIMS(point->flags) * sizeof(double);
440 
441  LWDEBUGF(3, "point size = %d", size);
442 
443  return size;
444 }
int npoints
Definition: liblwgeom.h:370
POINTARRAY * point
Definition: liblwgeom.h:410
uint8_t flags
Definition: liblwgeom.h:407
#define LWDEBUGF(level, msg,...)
Definition: lwgeom_log.h:88
#define FLAGS_NDIMS(flags)
Definition: liblwgeom.h:151

Here is the caller graph for this function: