Creates a leaf node given the pointer to the start point of the segment.
178 POSTGIS_DEBUGF(2,
"RTreeCreateLeafNode called for point %d of %p", startPoint, pa);
180 if (pa->
npoints < startPoint + 2)
182 lwpgerror(
"RTreeCreateLeafNode: npoints = %d, startPoint = %d", pa->
npoints, startPoint);
208 POSTGIS_DEBUGF(3,
"RTreeCreateLeafNode returning %p", parent);
The following struct and methods are used for a 1D RTree implementation, described at: http://lin-ear...
POINTARRAY * ptarray_construct_empty(char hasz, char hasm, uint32_t maxpoints)
Create a new POINTARRAY with no points.
struct rtree_node * leftNode
RTREE_INTERVAL * interval
int ptarray_append_point(POINTARRAY *pa, const POINT4D *pt, int allow_duplicates)
Append a point to the end of an existing POINTARRAY If allow_duplicate is LW_FALSE, then a duplicate point will not be added.
#define LW_TRUE
Return types for functions with status returns.
LWLINE * lwline_construct(int srid, GBOX *bbox, POINTARRAY *points)
#define SRID_UNKNOWN
Unknown SRID value.
struct rtree_node * rightNode
static RTREE_INTERVAL * RTreeCreateInterval(double value1, double value2)
Creates an interval given the min and max values, in arbitrary order.
void * lwalloc(size_t size)
int getPoint4d_p(const POINTARRAY *pa, int n, POINT4D *point)