MonoBehaviour.OnPreCull Manual     Reference     Scripting  
Scripting > Runtime Classes > MonoBehaviour

function OnPreCull () : void


OnPreCull is called before a camera culls the scene.

Culling determines which objects are visible to the camera. OnPreCull is called just before this process.

This function is called only if the script is attached to the camera.

If you want to change camera's viewing parameters (e.g. fieldOfView or just transform), this is the place to do it. Visibility of scene objects will be determined based on camera's parameters after OnPreCull.