spaceindex is a tool for building r-trees.
Add this to your Cargo.toml
:
toml
[dependencies]
spaceindex = "0.2"
To create a new RTree
, use:
```rust use spaceindex::rtree::RTree;
// Creates a 2-dimensional RTree let mut rtree = RTree::new(2);
// Insert a region into the tree rtree.insert(((0.0, 0.0), (3.0, 3.0)), 0).expect("failed to insert"); ```
Licensed under either of * Apache License, Version 2.0 (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0) * MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT) at your option.