Build a tree of nodes from a point array, one node per edge.
Definition at line 354 of file lwgeodetic_tree.c.
355{
356 int num_edges;
357 int i, j;
361
362
364 return NULL;
365
366
369
370
373 j = 0;
374 for ( i = 0; i < num_edges; i++ )
375 {
377 if ( node )
378 nodes[j++] = node;
379 }
380
381
382 if ( j == 0 ) {
385 }
386
387
389
390
392
393 return tree;
394}
void * lwalloc(size_t size)
static CIRC_NODE * circ_node_leaf_point_new(const POINTARRAY *pa)
Return a point node (zero radius, referencing one point)
static CIRC_NODE * circ_node_leaf_new(const POINTARRAY *pa, int i)
Create a new leaf node, storing pointers back to the end points for later.
static CIRC_NODE * circ_nodes_merge(CIRC_NODE **nodes, int num_nodes)
Note that p1 and p2 are pointers into an independent POINTARRAY, do not free them.
References circ_node_leaf_new(), circ_node_leaf_point_new(), circ_nodes_merge(), lwalloc(), lwfree(), and POINTARRAY::npoints.
Referenced by lwline_calculate_circ_tree(), lwpoint_calculate_circ_tree(), lwpoly_calculate_circ_tree(), test_tree_circ_create(), test_tree_circ_pip(), and test_tree_circ_pip2().