Massive Rigid Body Simulations

Is it possible to have massive, like 5,000 actors +, in a rigid simulation and still have a playable frame rate? I am just trying to figure out how far I can push the physics system in UE4 compared to UE3. Was there any under the hood improvements that would allow you to have much more rigid bodies in a simulation? Is this something that maybe you could possibly use GPU particles to do or are GPU particles better suited for smaller things like sparks or smaller particulate detail?

We have made several improvements to physics simulation in UE4. PhysX 3 is just faster than PhysX 2 for a start. Then we have an ‘async scene’ which simulates physics in parallel with game logic (though they lag behind by one frame). Then the integration and general engine framework is cleaner and more efficient.

Having said all that, 5,000 is a lot of bodies! Would they all be moving at once? Physics objects that are not moving have no game overhead, so it would just be the rendering overhead. Our current stress tests indicate that when you are moving very many objects, it is actually the renderer that becomes the bottleneck, but we are actively working to improve that. You can reduce the renderer overhead by using a skeletal mesh instead of individual static meshes for scenarios like this. That is how the APEX Destruction integration works.

Using particles (GPU or CPU) is a good way to simulate large numbers of moving objects efficiently when you do not need complex behavior (collisions, stacking, rolling etc).

Hey James,

Thanks for the detailed answer, it was just what I was looking for. 5k was just a number that I pulled out of the air purely for an example as its a massive number of object to be simulating. In all honestly they would not all not be moving at the same time and in the end there would also be much less of them. I just wanted to know if this was even in the realm of possibility and it sounds like it could be, be it that I do not use 5k actors.

Cheers-

Sam Deiter