Quick tip — How to set up Occlusion Culling in Unity

In this short article, I’ll explain how to set up occlusion culling in Unity.

Occlusion Culling is a very useful tool we have to help boost performance in our games. The process will cause specific elements of a scene to render only when necessary (for example, when a player is looking in that direction).

To mark an object as able to be occluded you need to go to the transform of that object and under the drop-down list next to the static indicator select “Occluder Static” and “Occludee Static”.

Next, go to “Window” > “Rendering” > “Occlusion Culling” and click “Bake” to set up the Occlusion data.

Now, click the visualization button to see the effects in the scene view.

Now in the game view, move your player around and watch as Unity renders objects in and out depending on where the player is looking.

That’s all for now.



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Luke Duckett

Luke Duckett

Unity developer with a love of learning all things programming.