Chaos::TAABBTree memory consumption and weird flat structure

Hi Eugene,

That is a very interesting find. It looks like the growth of our arrays is causing a higher memory cost than what we’d expect - but I can see how it is happening - there is always tradeoffs between how much memory is reserved vs how often we need to reseat an array in memory (to find a large enough area for it to be located in). Although we don’t do it - for the things which are pretty static, reserve() in the array would be really good to call since it skips the initial reseating of memory and gets an exact answer straight away (which also means less fragmentation).

In this scenario - elements may refer to shapes in this context (but as proxies - ie the bare minimum of information needed for the AABB) and the arrays are the objects/bodies - I am going to double check this though just to be sure.

Best

Geoff