splitice/QuadTrees

MaxObjectsPerNode should be a property when creating QuadTree

Closed this issue · 4 comments

MaxObjectsPerNode is now a const equals to 10.
I'd like to be able to set it when creating the QuadTree.
Thanks

Why? QuadTree's will split automatically.

That number was chosen based on extensive profiling. And should be fine for all use cases.

If it was to be made non-const profiling would be required illustrating no negative effect.

In my case I'd rather test with smaller number.
It's a small board area with sparse units most of the time.

Feel free to fork. I don't expect there would be any effect however. It's all about balancing indirection / locality with the costs of multiple checks. Sparseness should not be a factor.

Ok, thanks :)