Class ScriptableRenderPass
ScriptableRenderPass
implements a logical rendering pass that can be used to extend Universal RP renderer.
Inherited Members
Namespace: UnityEngine.Rendering.Universal
Assembly: Unity.RenderPipelines.Universal.Runtime.dll
Syntax
public abstract class ScriptableRenderPass
Constructors
Name | Description |
---|---|
ScriptableRenderPass() | Creates a new |
Fields
Name | Description |
---|---|
k_CameraTarget | RTHandle alias for BuiltinRenderTextureType.CameraTarget which is the backbuffer. |
Properties
Name | Description |
---|---|
clearColor | The color value to use when clearing. |
clearFlag | The flag to use when clearing. |
colorAttachmentHandle | The main color attachment handle. |
colorAttachmentHandles | List for the g-buffer attachment handles. |
colorStoreActions | The store actions for Color. |
depthAttachmentHandle | The depth attachment handle. |
depthStoreAction | The store actions for Depth. |
input | The input requirements for the |
profilingSampler | A ProfilingSampler for the entire render pass. Used as a profiling name by |
renderPassEvent | The event when the render pass executes. |
Methods
Name | Description |
---|---|
Blit(CommandBuffer, RTHandle, RTHandle, Material, int) | Add a blit command to the context for execution. This changes the active render target in the ScriptableRenderer to destination. |
Blit(CommandBuffer, ref RenderingData, Material, int) | Add a blit command to the context for execution. This applies the material to the color target. |
Blit(CommandBuffer, ref RenderingData, RTHandle, Material, int) | Add a blit command to the context for execution. This applies the material to the color target. |
Configure(CommandBuffer, RenderTextureDescriptor) | This method is called by the renderer before executing the render pass.
Override this method if you need to to configure render targets and their clear state, and to create temporary render target textures.
If a render pass doesn't override this method, this render pass renders to the active Camera's render target.
You should never call CommandBuffer.SetRenderTarget. Instead call |
ConfigureClear(ClearFlag, Color) | Configures clearing for the render targets for this render pass. Call this inside Configure. |
ConfigureColorStoreAction(RenderBufferStoreAction, uint) | Configures the Store Action for a color attachment of this render pass. |
ConfigureColorStoreActions(RenderBufferStoreAction[]) | Configures the Store Actions for all the color attachments of this render pass. |
ConfigureDepthStoreAction(RenderBufferStoreAction) | Configures the Store Action for the depth attachment of this render pass. |
ConfigureInput(ScriptableRenderPassInput) | Configures Input Requirements for this render pass.
This method should be called inside |
ConfigureTarget(RTHandle) | Configures render targets for this render pass. Call this instead of CommandBuffer.SetRenderTarget. This method should be called inside Configure. |
ConfigureTarget(RTHandle, RTHandle) | Configures render targets for this render pass. Call this instead of CommandBuffer.SetRenderTarget. This method should be called inside Configure. |
ConfigureTarget(RTHandle[]) | Configures render targets for this render pass. Call this instead of CommandBuffer.SetRenderTarget. This method should be called inside Configure. |
ConfigureTarget(RTHandle[], RTHandle) | Configures render targets for this render pass. Call this instead of CommandBuffer.SetRenderTarget. This method should be called inside Configure. |
CreateDrawingSettings(List<ShaderTagId>, ref RenderingData, SortingCriteria) | Creates |
CreateDrawingSettings(ShaderTagId, ref RenderingData, SortingCriteria) | Creates |
Execute(ScriptableRenderContext, ref RenderingData) | Execute the pass. This is where custom rendering occurs. Specific details are left to the implementation |
OnCameraCleanup(CommandBuffer) | Called upon finish rendering a camera. You can use this callback to release any resources created by this render pass that need to be cleanup once camera has finished rendering. This method be called for all cameras in a camera stack. |
OnCameraSetup(CommandBuffer, ref RenderingData) | This method is called by the renderer before rendering a camera
Override this method if you need to to configure render targets and their clear state, and to create temporary render target textures.
If a render pass doesn't override this method, this render pass renders to the active Camera's render target.
You should never call CommandBuffer.SetRenderTarget. Instead call |
OnFinishCameraStackRendering(CommandBuffer) | Called upon finish rendering a camera stack. You can use this callback to release any resources created by this render pass that need to be cleanup once all cameras in the stack have finished rendering. This method will be called once after rendering the last camera in the camera stack. Cameras that don't have an explicit camera stack are also considered stacked rendering. In that case the Base camera is the first and last camera in the stack. |
RecordRenderGraph(RenderGraph, FrameResources, ref RenderingData) | Record the render graph pass. This is where custom rendering occurs. Specific details are left to the implementation |
ResetTarget() | Resets render targets to default. This method effectively reset changes done by ConfigureTarget. |
Operators
Name | Description |
---|---|
operator >(ScriptableRenderPass, ScriptableRenderPass) | Compares two instances of |
operator <(ScriptableRenderPass, ScriptableRenderPass) | Compares two instances of |