Performance help when GPU bound

Need some advice on optimization. Right now it is obvious from a stat unit I am GPU bound. About 50% of that GPU cost is from 3 dynamic lights, 2 of which are casting dynamic shadows.

Can anyone suggest ways of optimizing while still keeping dynamic shadows?

Point

Spot

Rect

My scene is composed of 10-15000 instanced static meshes so the dynamic cast shadows are probably having a huge impact on performance.
00_Performance

Some ideas to help.

  • Try looking at the scene in the editor with shader complexity turned on.
    View Modes | Unreal Engine Documentation
  • You have 171 million primitives in the scene. That feels way too high. Can you reduce the polys and texture in far away objects some?
  • The two very expensive things that are the usual culprits are transparencies and lights. If transparent surfaces (like with an alpha of 0.5) overlap the rendering gets very slow. Too many light can slow rendering way down in particular if they cast shadows.
1 Like

Try to reduce the number of polys significantly. Try adding LODs for your meshes, perhaps?

Also, try running with a smaller window. If you’re running in 4k resolution on a laptop GPU, then that’s unlikely to be a good match between demand and performance, for example.

Turn on the hierarchical scene profiler (there’s docs on the Unreal docs site) and figure out which debug visualizations you can turn on/off to see where performance is going.

Finallly, break down and use a tool like NSight (if you’re on NVIDIA graphics) to measure the different parts of the scene.

1 Like