I’m loading objects at runtime from file using ProceduralMeshComponent.
Usually there are near 1 million of triangles in total and as a result I have ~12 FPS when walking on this scene.
Advise me please any ways to make my scene more lightweight.
Also I wonder if it’s possible to use LOD logic with ProceduralMeshComponent loaded at runtime?
I appreciate any help you can provide
1 million vertices usually doesn’t kill performance. However if you have a lot of mesh actors (Procedural mesh components), it will increase your draw call which will kill performance (try running this in console “stat SceneRendering”.
One way to reduce batch count is to merge similar meshes into a single mesh. So nearby meshes that share the same material can be merged into one
As an example, I’m working on a city generator right now and I push out all the vertices (~1.7M verts) in a single debug mesh to visualize the road meshes and the fps is 120fps (with a single large mesh)
Then I generate individual meshes (about 10,000 meshes) which sums up to the same number of vertices but the fps drops to about 30 (in my RTX2070) as the batch call is drastically increased
There’s also HLOD feature in UE4 which you might want to use but that works with static meshes
Thank you so much for the reply
Analyzing draw calls I found out that removing few lights and particles decrease the draw calls number (for 650 procedural meshes) from 4500 to 1000