Quadtree / Octree Matrix Implementation?

Federico-AmazingMaxStuff's icon

Hi everybody, I would like to know if exists a Quadtree / Octree implementation in C for Max.
An object that would handle 2D and 3D matrix input and sort the points into a tree.
Does this exist? I don't think this could be achieved in gen due to the recursive nature of the algorithm,
or am I wrong?
Thank you!

quat's icon

+1 - I would also like to see this in jit.gen (codebox, of course). I don't see why recursion would be a problem.