Do shader LOD's cause state changes, are they worth it?

Hello, I think having shader LOD to drop detail might be useful, but only if practical. I am unaware of the costs the would come from using LOD’s in a shader.

Are there state changes? Would the impact of switching shaders at a distance using the LOD be worse than just keeping them the same, and allowing culling/unloading when needed?

Is it worth using this shader function for realtime LOD purposes? The docs seem to only indicate the function being useful for adjusting to hardware specs, doesn’t say anything about dropping shaders during the game.

State changes happen whenever the state changes, and state includes the active shader.

In general, dynamic shader LOD is worth it when you have scenes that are really “deep” or where a given object may appear quite close/large on screen or quite small/far away. It also depends a lot on the hardware you are targeting. High end PC GPUs can just rip through shader code, where as last gen consoles or especially mobile really want things to be as simple as possible.

If you do real-time shader LOD, make sure that you can “fade out” the LOD’d aspects otherwise you’ll see gross popping all over the place.