Documentation
    Preparing search index...

    Interface GpuRenderPassDescriptor

    A render pass descriptor, reduced to what this packet attaches.

    interface GpuRenderPassDescriptor {
        colorAttachments: readonly {
            clearValue?: readonly [number, number, number, number];
            loadOp: "load" | "clear";
            storeOp: "store" | "discard";
            view: object;
        }[];
        depthStencilAttachment?: {
            depthClearValue?: number;
            depthLoadOp: "load"
            | "clear";
            depthStoreOp: "store" | "discard";
            stencilLoadOp?: "load" | "clear";
            stencilStoreOp?: "store" | "discard";
            view: object;
        };
        label?: string;
        timestampWrites?: {
            beginningOfPassWriteIndex?: number;
            endingOfPassWriteIndex?: number;
            querySet: GpuQuerySet;
        };
    }
    Index
    colorAttachments: readonly {
        clearValue?: readonly [number, number, number, number];
        loadOp: "load" | "clear";
        storeOp: "store" | "discard";
        view: object;
    }[]

    Colour attachments — exactly one in this tier.

    depthStencilAttachment?: {
        depthClearValue?: number;
        depthLoadOp: "load" | "clear";
        depthStoreOp: "store" | "discard";
        stencilLoadOp?: "load" | "clear";
        stencilStoreOp?: "store" | "discard";
        view: object;
    }

    The depth attachment, when the surface has one.

    Type Declaration

    • Optional ReadonlydepthClearValue?: number
    • ReadonlydepthLoadOp: "load" | "clear"
    • ReadonlydepthStoreOp: "store" | "discard"
    • Optional ReadonlystencilLoadOp?: "load" | "clear"

      Stencil-aspect ops (§67, WP-R1.3) — required by validation when the attachment's format carries a stencil aspect, and forbidden when it does not, which is why they are optional here and written only on a frame whose depth attachment is depth24plus-stencil8. Always "load": §61 confines clears to the viewport rectangle, so the stencil clear is a scissored draw per view, exactly as the colour and depth clears are.

    • Optional ReadonlystencilStoreOp?: "store" | "discard"
    • Readonlyview: object
    label?: string

    Diagnostic name.

    timestampWrites?: {
        beginningOfPassWriteIndex?: number;
        endingOfPassWriteIndex?: number;
        querySet: GpuQuerySet;
    }

    Timestamp writes for this pass (A-1). Optional, and omitted on every frame that has not armed GPU timing, so a tape that never reads lastGpuFrameTimeSeconds stays the object it always was.