32 G_debug(1,
"Vect_spatial_index_init()");
48 G_debug(1,
"Vect_spatial_index_destroy()");
66 static int rect_init = 0;
73 G_debug(3,
"Vect_spatial_index_add_item(): id = %d",
id);
97 static int rect_init = 0;
104 G_debug(3,
"Vect_spatial_index_del_item(): id = %d",
id);
116 G_fatal_error(
_(
"Unable to delete item %d from spatial index"),
id);
140 static int rect_init = 0;
157 G_debug(3,
"Vect_spatial_index_select(): %d items selected", list->
n_values);
void Vect_spatial_index_del_item(struct spatial_index *si, int id, const struct bound_box *box)
Delete item from spatial index structure.
int RTreeInsertRect(struct RTree_Rect *r, int tid, struct RTree *t)
Insert an item into a R*-Tree.
void void void void G_fatal_error(const char *,...) __attribute__((format(printf
int Vect_spatial_index_select(const struct spatial_index *si, const struct bound_box *box, struct ilist *list)
Select items by bounding box to list.
int Vect_reset_list(struct ilist *)
Reset ilist structure.
void RTreeDestroyTree(struct RTree *t)
Destroy an R*-Tree.
int RTreeSearch(struct RTree *t, struct RTree_Rect *r, SearchHitCallback *shcb, void *cbarg)
Search an R*-Tree.
int n_values
Number of values in the list.
int RTreeDeleteRect(struct RTree_Rect *r, int tid, struct RTree *t)
Delete an item from a R*-Tree.
struct RTree * si_tree
Pointer to the search tree (R*-Tree)
void G_ilist_add(struct ilist *, int)
Add item to ilist.
void Vect_spatial_index_destroy(struct spatial_index *si)
Destroy existing spatial index.
unsigned char nsides_alloc
void Vect_spatial_index_add_item(struct spatial_index *si, int id, const struct bound_box *box)
Add a new item to spatial index structure.
int G_debug(int, const char *,...) __attribute__((format(printf
void Vect_spatial_index_init(struct spatial_index *si, int with_z)
Initialize spatial index structure.
struct RTree * RTreeCreateTree(int fd, off_t rootpos, int ndims)
Create new empty R*-Tree.