Skip to content
anvakaPublic

About

Yet another quad tree

Resources

Stars

7 stars

Watchers

1 watching

Forks

Latest commit

 

History

20 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

yaqt Build Status

Yet another quad tree. API is not finished. Just a test. You can see yaot for 3D oct-tree, which is used and better documented.

usage

These notes are for myself:

npm install https://github.com/anvaka/yaqt
// First we need to create the tree:
var createTree = require('yaqt');

var tree = createTree();
var points = [
  0, 0, // First point at 0, 0, 0
  10, 0 // second point at 10, 0, 0
]
tree.init(points);

tree.pointsAround(
  5 // x center of the square
  5 // y center of the square,
  6 // half width of the square
);
// this will return indices 0 and 2 of the original points array, since both 0, 0
// and 10, 0 ar lying within requested square

license

MIT

About

Yet another quad tree

Resources

Stars

7 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages