docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Interface IBaseRenderGraphBuilder

    Common base interface for the different render graph builders. These functions are supported on all builders.

    Inherited Members
    IDisposable.Dispose()
    Namespace: UnityEngine.Experimental.Rendering.RenderGraphModule
    Assembly: Unity.RenderPipelines.Core.Runtime.dll
    Syntax
    public interface IBaseRenderGraphBuilder : IDisposable

    Methods

    AllowGlobalStateModification(bool)

    Allow commands in the command buffer to modify global state. This will introduce a render graph sync-point in the frame and cause all passes after this pass to never be reordered before this pass. This may nave negative impact on performance and memory use if not used carefully so it is recommended to only allow this in specific use cases. This will also set AllowPassCulling to false.

    Declaration
    void AllowGlobalStateModification(bool value)
    Parameters
    Type Name Description
    bool value

    True to allow global state modification.

    AllowPassCulling(bool)

    Allow or not pass culling By default all passes can be culled out if the render graph detects it's not actually used. In some cases, a pass may not write or read any texture but rather do something with side effects (like setting a global texture parameter for example). This function can be used to tell the system that it should not cull this pass.

    Declaration
    void AllowPassCulling(bool value)
    Parameters
    Type Name Description
    bool value

    True to allow pass culling.

    CreateTransientBuffer(in BufferDesc)

    Create a new Render Graph Graphics Buffer resource. This Graphics Buffer will only be available for the current pass and will be assumed to be both written and read so users don't need to add explicit read/write declarations.

    Declaration
    BufferHandle CreateTransientBuffer(in BufferDesc desc)
    Parameters
    Type Name Description
    BufferDesc desc

    Compute Buffer descriptor.

    Returns
    Type Description
    BufferHandle

    A new transient BufferHandle.

    CreateTransientBuffer(in BufferHandle)

    Create a new Render Graph Graphics Buffer resource using the descriptor from another Graphics Buffer. This Graphics Buffer will only be available for the current pass and will be assumed to be both written and read so users don't need to add explicit read/write declarations.

    Declaration
    BufferHandle CreateTransientBuffer(in BufferHandle computebuffer)
    Parameters
    Type Name Description
    BufferHandle computebuffer

    Graphics Buffer from which the descriptor should be used.

    Returns
    Type Description
    BufferHandle

    A new transient BufferHandle.

    CreateTransientTexture(in TextureDesc)

    Create a new Render Graph Texture resource. This texture will only be available for the current pass and will be assumed to be both written and read so users don't need to add explicit read/write declarations.

    Declaration
    TextureHandle CreateTransientTexture(in TextureDesc desc)
    Parameters
    Type Name Description
    TextureDesc desc

    Texture descriptor.

    Returns
    Type Description
    TextureHandle

    A new transient TextureHandle.

    CreateTransientTexture(in TextureHandle)

    Create a new Render Graph Texture resource using the descriptor from another texture. This texture will only be available for the current pass and will be assumed to be both written and read so users don't need to add explicit read/write declarations.

    Declaration
    TextureHandle CreateTransientTexture(in TextureHandle texture)
    Parameters
    Type Name Description
    TextureHandle texture

    Texture from which the descriptor should be used.

    Returns
    Type Description
    TextureHandle

    A new transient TextureHandle.

    EnableAsyncCompute(bool)

    Enable asynchronous compute for this pass.

    Declaration
    void EnableAsyncCompute(bool value)
    Parameters
    Type Name Description
    bool value

    Set to true to enable asynchronous compute.

    UseBuffer(in BufferHandle, AccessFlags)

    Declare that this pass uses the input compute buffer.

    Declaration
    BufferHandle UseBuffer(in BufferHandle input, IBaseRenderGraphBuilder.AccessFlags flags = AccessFlags.Read)
    Parameters
    Type Name Description
    BufferHandle input

    The compute buffer resource to use during the pass.

    IBaseRenderGraphBuilder.AccessFlags flags

    A combination of flags indicating how the resource will be used during the pass. Default value is set to AccessFlag.Read

    Returns
    Type Description
    BufferHandle

    A explicitly versioned handle representing the latest version of the pased in texture. Note that except for special cases where you want to refer to a specific version return value is generally discarded.

    UseRendererList(in RendererListHandle)

    This pass will read from this renderer list. RendererLists are always read-only in the graph so have no access flags.

    Declaration
    void UseRendererList(in RendererListHandle input)
    Parameters
    Type Name Description
    RendererListHandle input

    The Renderer List resource to use during the pass.

    UseTexture(in TextureHandle, AccessFlags)

    Declare that this pass uses the input texture.

    Declaration
    TextureHandle UseTexture(in TextureHandle input, IBaseRenderGraphBuilder.AccessFlags flags = AccessFlags.Read)
    Parameters
    Type Name Description
    TextureHandle input

    The texture resource to use during the pass.

    IBaseRenderGraphBuilder.AccessFlags flags

    A combination of flags indicating how the resource will be used during the pass. Default value is set to AccessFlag.Read

    Returns
    Type Description
    TextureHandle

    A explicitly versioned handle representing the latest version of the pased in texture. Note that except for special cases where you want to refer to a specific version return value is generally discarded.

    Extension Methods

    AnalyticsUtils.ToNestedColumnWithDefault<T>(T, T, bool)
    In This Article
    Back to top
    Copyright © 2024 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)