Documentation
    Preparing search index...

    Class TextureAsset

    A decoded texture with an explicit lifetime (§83), shaped as @fourjs/render's TextureSource (§61, §77).

    new Texture(asset) takes it directly. dispose drops the texel buffer — the one large allocation a texture asset owns — so releasing the last reference in the AssetManager actually frees it; a disposed asset reports a 1 × 1 empty source rather than throwing, matching the renderer's own post-disposal posture.

    Implements

    Index
    colorSpace: TextureColorSpace | undefined

    §60a colour space, or undefined for the renderer's default.

    filter: TextureFilterMode | undefined

    §77 filter mode, or undefined for the renderer's default.

    wrap: TextureWrapMode | undefined

    §77 wrap mode, or undefined for the renderer's default.

    • get data(): Uint8Array

      Tightly packed RGBA8 texels, bottom row first (§7a).

      Returns Uint8Array

    • get height(): number

      Height in texels.

      Returns number

    • get isDisposed(): boolean

      Whether dispose has already released the texels.

      Returns boolean

    • get width(): number

      Width in texels.

      Returns number