Version: 2022.3
LanguageEnglish
  • C#

CameraEvent

enumeration

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Description

Defines a place in camera's rendering to attach CommandBuffer objects to.

Unity's rendering loop can be extended by adding so called "command buffers" at various points in camera rendering. For example, you could add some custom geometry to be drawn right after the skybox is drawn.

Additional resources: CommandBuffer, LightEvent, command buffers overview.

Properties

BeforeDepthTextureBefore camera's depth texture is generated.
AfterDepthTextureAfter camera's depth texture is generated.
BeforeDepthNormalsTextureBefore camera's depth+normals texture is generated.
AfterDepthNormalsTextureAfter camera's depth+normals texture is generated.
BeforeGBufferBefore deferred rendering G-buffer is rendered.
AfterGBufferAfter deferred rendering G-buffer is rendered.
BeforeLightingBefore lighting pass in deferred rendering.
AfterLightingAfter lighting pass in deferred rendering.
BeforeFinalPassBefore final geometry pass in deferred lighting.
AfterFinalPassAfter final geometry pass in deferred lighting.
BeforeForwardOpaqueBefore opaque objects in forward rendering.
AfterForwardOpaqueAfter opaque objects in forward rendering.
BeforeImageEffectsOpaqueBefore image effects that happen between opaque & transparent objects.
AfterImageEffectsOpaqueAfter image effects that happen between opaque & transparent objects.
BeforeSkyboxBefore skybox is drawn.
AfterSkyboxAfter skybox is drawn.
BeforeForwardAlphaBefore transparent objects in forward rendering.
AfterForwardAlphaAfter transparent objects in forward rendering.
BeforeImageEffectsBefore image effects.
AfterImageEffectsAfter image effects.
AfterEverythingAfter camera has done rendering everything.
BeforeReflectionsBefore reflections pass in deferred rendering.
AfterReflectionsAfter reflections pass in deferred rendering.
BeforeHaloAndLensFlaresBefore halo and lens flares.
AfterHaloAndLensFlaresAfter halo and lens flares.
Copyright © 2023 Unity Technologies
优美缔软件(上海)有限公司 版权所有
"Unity"、Unity 徽标及其他 Unity 商标是 Unity Technologies 或其附属机构在美国及其他地区的商标或注册商标。其他名称或品牌是其各自所有者的商标。
公安部备案号:
31010902002961