A simple octree implementation in C++