PIXI.KTXLoader

class KTXLoader implements {PIXI.ILoaderPlugin}

Loader plugin for handling KTX texture container files.

This KTX loader does not currently support the following features:

  • cube textures
  • 3D textures
  • endianness conversion for big-endian machines
  • embedded *.basis files

It does supports the following features:

Constructor


new PIXI.KTXLoader() → {}

Loader plugin for handling KTX texture container files.

Summary


Properties from KTXLoader

Methods from KTXLoader

void
static use(resource: PIXI.LoaderResource, next: (...args: any[]) => void)

Called after a KTX file is loaded.

Public Properties


loadKeyValueData KTXLoader.ts:33
static loadKeyValueData: boolean = false

If set to true, PIXI.KTXLoader will parse key-value data in KTX textures. This feature relies on the Encoding Standard.

The key-value data will be available on the base-textures as PIXI.BaseTexture.ktxKeyValueData. They will hold a reference to the texture data buffer, so make sure to delete key-value data once you are done using it.

Public Methods


use KTXLoader.ts:43
static use(resource: PIXI.LoaderResource, next: (...args: any[]) => void) → {void}

Called after a KTX file is loaded.

This will parse the KTX file header and add a BaseTexture to the texture cache.

Parameters:
Name Type Description
resource PIXI.LoaderResource

loader resource that is checked to see if it is a KTX file

next (...args: any[]) => void

callback Function to call when done

Returns:
Type Description
void
See: PIXI.Loader.loaderMiddleware

Powered by webdoc!