Archive 17/01/2023.

Memory pool

sabotage3d

Hi guys,
Have anyone implemented a memory pool for Urho3D? What would be the best way to approach this?

hdunderscore

Although I haven’t used them, Urho has Allocator class which might be used for that.

In one project where I had many projectiles firing, I made a simple Vector pool, that gave a notable performance improvement.

sabotage3d

Ah cool I didn’t know about that. Can it be used to create a pool for Urho3D’s smart pointers and containers?

Modanung

Yes, heXon’s SpawnMaster does object pooling too. Basically using a single template function.