Dynamic Occlusion Flickering in Unity 2020.3.1f1 LTS

Hello!

When I upgraded my project from Unity 2019.4.16f1 to 2020.3.1f1 LTS, dynamic occlusion no longer functions properly. I am using URP and it is a VR project. When I look in certain directions, some meshes flicker or disappear. If I turn off dynamic occlusion on an individual mesh, then that mesh no longer flickers so I know the issue is related to dynamic occlusion. I don’t consider turning off dynamic occlusion to be a “fix” - I need it for performance reasons.

Video:

This issue did not occur in Unity 2019, and began as a direct result of upgrading the project to 2020.3.1f1 LTS. Re-baking occlusion in the scene does not help at all.

Does anyone know how to fix this issue? Any help is greatly appreciated!

I was able to track down and fix the issue. It turns out newer versions of unity don’t like it when you have the camera far clip plane set too high. It seriously screws up Unity’s dynamic occlusion raycasting when the camera is facing certain angles.

Here’s before i fixed it. The camera’s far clip plane is set to 100,000 units:

And here it is with the far clip plane set to a lower value of 10,000 units:

I had it set very far because I had some distant geometry in one of my scenes. I didn’t think it mattered how far I set it, but in newer versions of Unity, apparently it does.

1 Like