Engine API Reference
    Preparing search index...

    Class BindStorageTextureFormat

    A class to describe the format of the storage texture for BindGroupFormat. Storage texture is a texture created with the storage flag set to true, which allows it to be used as an output of a compute shader.

    Note: At the current time, storage textures are only supported in compute shaders in a write-only mode.

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    Constructors

    • Create a new instance.

      Parameters

      • name: string

        The name of the storage buffer.

      • Optionalformat: number = PIXELFORMAT_RGBA8

        The pixel format of the texture. Note that not all formats can be used. Defaults to PIXELFORMAT_RGBA8.

      • OptionaltextureDimension: string = TEXTUREDIMENSION_2D
      • Optionalwrite: boolean = true

        Whether the storage texture is writeable. Defaults to true.

      • Optionalread: boolean = false

        Whether the storage texture is readable. Defaults to false. Note that storage texture reads are only supported if GraphicsDevice#supportsStorageTextureRead is true. Also note that only a subset of pixel formats can be used for storage texture reads - as an example, PIXELFORMAT_RGBA8 is not compatible, but PIXELFORMAT_R32U is.

      Returns BindStorageTextureFormat

    Properties

    name: string