Nano WebGPU API - v0.11.0
    Preparing search index...

    Class BloomSystem

    BloomSystem manages the multi-pass bloom post-processing effect. Uses a bright-pass extraction followed by separable Gaussian blur ping-pong, producing a bloom texture that the final post-process shader blends additively.

    Index

    Accessors

    Constructors

    Methods

    Properties

    Accessors

    • get bloomTextureView(): GPUTextureView

      The final bloom texture view to bind in the post-process pass. After renderPasses(), this contains the blurred bright regions. When bloom is disabled it is still a valid (black) texture.

      Returns GPUTextureView

    Constructors

    Methods

    • Executes all bloom render passes (bright-pass + N×blur) into the ping-pong textures. Call this between the main render pass and the post-process pass.

      Parameters

      • ctx: Context

        Active context.

      • commandEncoder: GPUCommandEncoder

        Current frame command encoder.

      Returns void

    • Reallocates bloom ping-pong textures to match the new canvas dimensions. Must be called whenever the canvas resizes.

      Parameters

      • ctx: Context

        Active context.

      • width: number

        New canvas pixel width.

      • height: number

        New canvas pixel height.

      • sceneTextureView: GPUTextureView

        The main scene color texture view (for the bright-pass bind group).

      Returns void

    Properties

    options: BloomOptions

    Active bloom configuration options.