Skip to main content

CameraRenderEvents

A class in Root.Township, Alta.ScreenshotCamera.

Component added to a Unity camera to forward its pre-cull and post-render callbacks to actions.

Constructors​

MemberWhat it is
CameraRenderEvents()Unity makes components itself; use AddComponent or spawn a prefab instead of new.

Events​

2 private and internal events
MemberWhat it is
private event Action onPostRenderActions run after the camera renders.
private event Action onPreCullActions run before the camera culls.

Methods​

MemberWhat it is
static void AddCamera(Camera camera, Action onPreCull, Action onPostRender)Adds or gets the component on a camera and subscribes the two actions.
2 private and internal methods
MemberWhat it is
private void OnPostRender()Unity callback; raises onPostRender.
private void OnPreCull()Unity callback; raises onPreCull.