How to turn off LODs completely

Hi there!
Does anyone know how to turn off LODs completely and only force the highest LOD?
I’m creating some high quality renders with the Big City city sample level. Most of the time I haven’t had problems with LODs “popping” and flickering between states, but when I do big flyover shots of the city, it becomes very obvious.
Performance isn’t an issue for me as I would rather my renders take longer and not switch LODs, rather than being faster and less performance heavy. They are all instanced meshes but there’s so many of them, is there a better way than going into every static mesh and turning LODs off?
I already have r.ForceLOD0 and r.LODDistanceScale0 and r.TextureStreaming0 set in my console variables of my render.
Thank you!

1 Like

Hey there @ruffstuff70! I was going to recommend r.ForceLOD0, but you seem to be way ahead of me there. If you need to change them directly on the objects, you may be able to create and editor utility or python script. I believe you can process them with

set_lods_with_notification(static_mesh, reduction_options, apply_changes)

If you work with Python at all.

Documentation here:
https://docs.unrealengine.com/5.0/en-US/PythonAPI/class/EditorStaticMeshLibrary.html?highlight=set_lods_with_notification#unreal.EditorStaticMeshLibrary.set_lods_with_notification

Hey SupportiveEntity, thank you so much! I haven’t worked a ton with python but I’ll give that a try. My only issue is that the city sample doesn’t used static mesh, but nanite instead.
Is this beyond forcing LOD and getting into a streaming issue?

Sorry, that script probably won’t help with nanite meshes. Nanite only uses the LOD0 for it’s fallback mesh generation, so it’s nanite’s downscaling of the mesh that’s causing it. Since it only uses fallbacks for when you’re on a non-Nanite system.

You might be able to mess with the Nanite LOD offset commands in the console.

Try disabling the world streaming

This is impossible with the size of the City Sample being 8 kilometres length and width. It’s too much to not stream - your unreal will automatically crash

1 Like