A lightweight visualizer for an Octree spatial querying system. View the visualizer here.
An Octree is a data structure is used for efficient spatial querying and is created by recursively dividing a 3D space into 8 cubes. These 8 cubes can be thought of as children of a parent node, and each also contain 8 children of their own.
Actions like clash detection, nearest neighbor calculation and raycasting break down when the number of objects in the scene becomes too large. An octree speeds this up by pruning entire areas of the scene, reducing the total number of calculations which need to be done. The accompanying write-up explains this in-depth.
Octrees are used widely in Game Development, Clash Detection, K-Nearest Neighbors Algorithms and many other fields.
This demo serves to educate on the mechanics behind how an Octree works, and is intended to be a lightweight implementation that could potentially sit as a layer within larger 3D scenes.
Classic-Roblox-Rubber-Duckie by fog. CC License.

