@pixi/3d
    Preparing search index...

    Interface GraphRenderPassAdvanced

    What RenderGraph#addPass takes: a RenderPass, or a plain object with name, setup and render

    interface GraphRenderPass {
        bit?: number;
        camera?: Camera3D | null;
        description?: string;
        name: string;
        condition?(session: RenderSession): boolean;
        destroy?(): void;
        prepare?(session: RenderSession): void;
        render(session: RenderSession): void;
        setup(builder: PassBuilder): void;
        unload?(): void;
    }
    Index
    bit?: number

    The RenderPassBit of the meshes the pass draws; give RenderPassBit.NONE on a pass that draws none

    camera?: Camera3D | null

    Camera this pass draws from, or null or absent for the view's own

    A camera with a render texture draws into that texture. Any other camera draws into its frame within the view: while render runs on a pass with attachments, the GPU viewport and session.activeViewport cover only that frame.

    description?: string

    What the pass adds to the frame, shown by debug tools

    name: string

    Names the pass in errors and debug tools

    • Return false to skip the pass this frame, prepare included, and any pass that only feeds it

      A later pass that reads what this one writes isn't skipped with it, and sees whatever the texture last held. For a texture the graph allocates, that can be another pass's leftovers; to keep a result across skipped frames, write it into one you import with RenderGraph#importColor.

      Parameters

      Returns boolean

      Whether the pass runs this frame.

    • Releases the pass; the graph calls it once, when it is destroyed

      Returns void

    • Runs on each frame the pass runs, before any pass renders, for uploads and compute work such as culling; the cameras are already updated

      Parameters

      Returns void

    • Draws the pass on each frame it runs, after the graph binds the textures it samples and any target it declared

      Parameters

      Returns void

    • Declares the textures the pass reads and writes; runs once, when the pass is added

      Parameters

      • builder: PassBuilder

        Records the declarations for this pass.

      Returns void

    • Frees GPU memory the pass can rebuild, such as the shadow pass's map; RenderGraph#unload calls it

      It can run any number of times and the pass keeps rendering, so whatever it frees must come back on the next frame that needs it.

      Returns void