Class BlobResourceAbstract

Resource that fetches texture data over the network and stores it in a buffer.

Memberof

PIXI

Hierarchy (view full)

Constructors

Properties

The data of this resource.

destroyed: boolean

If resource has been destroyed.

Default

false
internal: boolean

true if resource is created by BaseTexture useful for doing cleanup with BaseTexture destroy and not cleaning up resources that were created externally.

src: string

The url of the resource

unpackAlignment: 1 | 2 | 4 | 8

The alignment of the rows in the data.

Accessors

  • get height(): number
  • The height of the resource.

    Returns number

  • get valid(): boolean
  • Has been validated

    Returns boolean

  • get width(): number
  • The width of the resource.

    Returns number

Methods

  • Call when destroying resource, unbind any BaseTexture object before calling this method, as reference counts are maintained internally.

    Returns void

  • Destroy and don't use after this.

    Returns void

  • Loads the blob

    Returns Promise<BlobResource>

  • Trigger a resize event

    Parameters

    • width: number

      X dimension

    • height: number

      Y dimension

    Returns void

  • Set the style, optional to override

    Parameters

    Returns boolean

    • true is success
  • Has been updated trigger event.

    Returns void

  • Upload the texture to the GPU.

    Parameters

    Returns boolean

    • true is success
  • Used to auto-detect the type of resource.

    Parameters

    • source: unknown

      The source object

    Returns source is BufferType

    true if buffer source

Generated using TypeDoc