An open API service indexing awesome lists of open source software.

https://github.com/threeletters/binaryspacetree

Simple 2d binary space tree for Javascript
https://github.com/threeletters/binaryspacetree

Last synced: about 1 year ago
JSON representation

Simple 2d binary space tree for Javascript

Awesome Lists containing this project

README

          

# BinarySpaceTree
Simple 2d binary space tree for Javascript

## Usage

```js
var tree = new Tree(width,height)

var node = {
bounds: {
minX: 0,
minY: 0,
maxX: 100,
maxY: 100
}
}

tree.insert(node)

tree.forEach({
minX: 0,
minY: 0,
maxX: 100,
maxY: 100
},(n)=>{
console.log(n)
})
```