PostGIS  2.5.1dev-r@@SVN_REVISION@@

◆ lwpoint_from_twkb_state()

static LWPOINT* lwpoint_from_twkb_state ( twkb_parse_state s)


Definition at line 221 of file lwin_twkb.c.

References twkb_parse_state::has_m, twkb_parse_state::has_z, twkb_parse_state::is_empty, LWDEBUG, lwpoint_construct(), lwpoint_construct_empty(), ptarray_from_twkb_state(), and SRID_UNKNOWN.

Referenced by lwgeom_from_twkb_state(), and lwmultipoint_from_twkb_state().

222 {
223  static uint32_t npoints = 1;
224  POINTARRAY *pa;
226  LWDEBUG(2,"Entering lwpoint_from_twkb_state");
228  if ( s->is_empty )
231  pa = ptarray_from_twkb_state(s, npoints);
232  return lwpoint_construct(SRID_UNKNOWN, NULL, pa);
233 }
uint8_t has_z
Definition: lwin_twkb.c:49
uint8_t is_empty
Definition: lwin_twkb.c:51
uint8_t has_m
Definition: lwin_twkb.c:50
#define LWDEBUG(level, msg)
Definition: lwgeom_log.h:83
static POINTARRAY * ptarray_from_twkb_state(twkb_parse_state *s, uint32_t npoints)
POINTARRAY Read a dynamically sized point array and advance the parse state forward.
Definition: lwin_twkb.c:172
LWPOINT * lwpoint_construct_empty(int srid, char hasz, char hasm)
Definition: lwpoint.c:151
unsigned int uint32_t
Definition: uthash.h:78
Unknown SRID value.
Definition: liblwgeom.h:187
LWPOINT * lwpoint_construct(int srid, GBOX *bbox, POINTARRAY *point)
Definition: lwpoint.c:129
Here is the call graph for this function:
Here is the caller graph for this function: