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

◆ unroll_collection()

static void unroll_collection ( LWPOINTITERATOR s)
static

Remove an LWCOLLECTION from the iterator stack, and add the components of the LWCOLLECTIONs to the stack.

Definition at line 118 of file lwiterator.c.

119{
120 int i;
121 LWCOLLECTION* c;
122
123 if (!s->geoms)
124 {
125 return;
126 }
127
128 c = (LWCOLLECTION*) s->geoms->item;
129 s->geoms = pop_node(s->geoms);
130
131 for (i = c->ngeoms - 1; i >= 0; i--)
132 {
133 const LWGEOM* g = lwcollection_getsubgeom(c, i);
134
136 }
137}
char * s
Definition cu_in_wkt.c:23
const LWGEOM * lwcollection_getsubgeom(LWCOLLECTION *col, uint32_t gnum)
static int add_lwgeom_to_stack(LWPOINTITERATOR *s, const LWGEOM *g)
Definition lwiterator.c:71
static LISTNODE * pop_node(LISTNODE *i)
Definition lwiterator.c:63
uint32_t ngeoms
Definition liblwgeom.h:580
LWGEOM ** geoms
Definition liblwgeom.h:575

References add_lwgeom_to_stack(), LWCOLLECTION::geoms, lwcollection_getsubgeom(), LWCOLLECTION::ngeoms, pop_node(), and s.

Referenced by unroll_collections().

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