Skip to content

Javascript Octree / Quadtree implementation with focus on performance

Notifications You must be signed in to change notification settings

denisnarushevich/octree.js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Octree

JavaScript Octree / Quadtree implementation, with focus on performance

There is still an areas of possible performance improvement.

Octree can also be used as quadtree, just drop Z values.

Features

  • Maximally bitwise
  • Supports AABB and POINT
  • Without dependencies
  • UMD

Usage

Just inherit your object from Octree.Item and insert it into octree instance.

...
var octree = new Octree();
var item = new Octree.Item(x,y,z,ex,ey,ez); //ex,ey,ez is required only for AABB item
octree.insert(item);
var items = [];
octree.retrieve(item, items); //retrieve items from octant of provided item

About

Javascript Octree / Quadtree implementation with focus on performance

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages