Interface IRasterRenderGraphBuilder
A builder for a raster render pass. AddRasterRenderPass<PassData>(string, out PassData)
Inherited Members
Namespace: UnityEngine.Rendering.RenderGraphModule
Assembly: Unity.RenderPipelines.Core.Runtime.dll
Syntax
[MovedFrom(true, "UnityEngine.Experimental.Rendering.RenderGraphModule", "UnityEngine.Rendering.RenderGraphModule", null)]
public interface IRasterRenderGraphBuilder : IRenderAttachmentRenderGraphBuilder, IBaseRenderGraphBuilder, IDisposable
Methods
SetExtendedFeatureFlags(ExtendedFeatureFlags)
Enables the configuration of extended pass properties that may allow platform-specific optimizations.
Declaration
void SetExtendedFeatureFlags(ExtendedFeatureFlags extendedFeatureFlags)
Parameters
| Type | Name | Description |
|---|---|---|
| ExtendedFeatureFlags | extendedFeatureFlags | Specifies additional pass properties that may enable optimizations on certain platforms. |
SetInputAttachment(TextureHandle, int, AccessFlags)
Binds the texture as an input attachment for this pass.
Shaders might read this texture at the current fragment using
LOAD_FRAMEBUFFER_INPUT(idx) or LOAD_FRAMEBUFFER_INPUT_MS(idx, sampleIdx).
The idx used in the shader must match the index provided to SetInputAttachment.
Declaration
void SetInputAttachment(TextureHandle tex, int index, AccessFlags flags = AccessFlags.Read)
Parameters
| Type | Name | Description |
|---|---|---|
| TextureHandle | tex | The texture to expose as an input attachment. |
| int | index | The binding index used by the shader macros ( |
| AccessFlags | flags | The access mode for this texture. Defaults to |
Remarks
Platform support varies. Input attachments, especially with MSAA, might be unsupported on
some targets. Use RenderGraphUtils.IsFramebufferFetchSupportedOnCurrentPlatform at
runtime to check compatibility.
SetInputAttachment(TextureHandle, int, AccessFlags, int, int)
Binds the texture as an input attachment for this pass.
Shaders might read this texture at the current fragment using
LOAD_FRAMEBUFFER_INPUT(idx) or LOAD_FRAMEBUFFER_INPUT_MS(idx, sampleIdx).
The idx used in the shader must match the index provided in SetInputAttachment.
Declaration
void SetInputAttachment(TextureHandle tex, int index, AccessFlags flags, int mipLevel, int depthSlice)
Parameters
| Type | Name | Description |
|---|---|---|
| TextureHandle | tex | The texture to expose as an input attachment. |
| int | index | The binding index used by the shader macros ( |
| AccessFlags | flags | The access mode for the texture. Defaults to |
| int | mipLevel | The mip level to bind. |
| int | depthSlice | The array slice to bind. Use -1 to bind all slices. |
Remarks
Platform support varies. Input attachments, especially with MSAA, might be unsupported on
some targets. Use RenderGraphUtils.IsFramebufferFetchSupportedOnCurrentPlatform at
runtime to check compatibility.
SetRenderFunc<PassData>(BaseRenderFunc<PassData, RasterGraphContext>)
Specify the render function to use for this pass. A call to this is mandatory for the pass to be valid.
Declaration
void SetRenderFunc<PassData>(BaseRenderFunc<PassData, RasterGraphContext> renderFunc) where PassData : class, new()
Parameters
| Type | Name | Description |
|---|---|---|
| BaseRenderFunc<PassData, RasterGraphContext> | renderFunc | Render function for the pass. |
Type Parameters
| Name | Description |
|---|---|
| PassData | The Type of the class that provides data to the Render Pass. |
SetShadingRateCombiner(ShadingRateCombinerStage, ShadingRateCombiner)
Set shading rate combiner.
Declaration
void SetShadingRateCombiner(ShadingRateCombinerStage stage, ShadingRateCombiner combiner)
Parameters
| Type | Name | Description |
|---|---|---|
| ShadingRateCombinerStage | stage | Shading rate combiner stage to apply combiner to. |
| ShadingRateCombiner | combiner | Shading rate combiner to set. |
SetShadingRateFragmentSize(ShadingRateFragmentSize)
Set shading rate fragment size.
Declaration
void SetShadingRateFragmentSize(ShadingRateFragmentSize shadingRateFragmentSize)
Parameters
| Type | Name | Description |
|---|---|---|
| ShadingRateFragmentSize | shadingRateFragmentSize | Shading rate fragment size to set. |
SetShadingRateImageAttachment(in TextureHandle)
Enables Variable Rate Shading (VRS) on the current rasterization pass. Rasterization will use the texture to determine the rate of fragment shader invocation.
Declaration
void SetShadingRateImageAttachment(in TextureHandle tex)
Parameters
| Type | Name | Description |
|---|---|---|
| TextureHandle | tex | Shading rate image (SRI) Texture to use during this pass. |