System.IDisposable AddHookAfterOpaque( string debugName, int order, System.Action<SceneCamera> renderEffect )

book_4_sparkGenerated
code_blocksInput

Description

The AddHookAfterOpaque method allows you to add a custom rendering hook that executes after the opaque rendering stage in the camera's rendering pipeline. This method is marked as obsolete, indicating that it may be removed in future versions and should be avoided in new code.

Usage

To use this method, provide a debugName for identification, an order to determine the execution sequence among other hooks, and a renderEffect action that defines the rendering logic to be executed.

Example

// Example usage of AddHookAfterOpaque
CameraComponent cameraComponent = new CameraComponent();

using (cameraComponent.AddHookAfterOpaque("MyDebugHook", 10, (sceneCamera) =>
{
    // Custom rendering logic here
}))
{
    // The hook is active within this using block
}