At runtime, Unity loads only one occlusion cullingA that disables rendering of objects when they are not currently seen by the camera because they are obscured (occluded) by other objects. More info
See in Glossary data asset at a time, no matter how many ScenesA Scene contains the environments and menus of your game. Think of each unique Scene file as a unique level. In each Scene, you place your environments, obstacles, and decorations, essentially designing and building your game in pieces. More info
See in Glossary are open. You must therefore prepare your occlusion culling data differently depending on whether you plan to load one Scene at a time, or multiple Scenes at a time.
If you load one Scene at a time with LoadSceneMode.Single, you must bake the occlusion culling data for each Scene separately, like this:
At runtime, load your Scenes like this:
If you load multiple Scenes at a time with LoadSceneMode.Additive, you must bake the data for those Scenes together, like this:
At runtime, load your Scenes like this:
LoadSceneMode.Single
. Unity unloads the active Scene if there is one, along with its occlusion data asset if it has one. Unity then loads your Scene along with the shared occlusion data asset.LoadSceneMode.Additive
. If Unity finds that the the occlusion data of an additively loaded Scene is the same as that of the active Scene, occlusion culling works as intended.Note that the shared occlusion data asset has a larger file size. There is no additional runtime CPU impact to using a larger occlusion data asset.
For further information on working with multiple Scenes in the Unity Editor, see the documentation on multi-Scene editing.