PIXI.TextureSystem

class TextureSystem implements PIXI.ISystem

System plugin to the renderer to manage textures.

Constructor


new PIXI.TextureSystem(renderer: PIXI.Renderer) → {}
Parameters:
Name Type Description
renderer PIXI.Renderer

The renderer this system works for.

Summary


Properties from TextureSystem

Methods from TextureSystem

void
bind(texture: PIXI.Texture | PIXI.BaseTexture, location: number)

Bind a texture to a specific location

void
contextChange()

Sets up the renderer context and necessary buffers.

void
ensureSamplerType(maxTextures: number)
void
reset()

Resets texture location and bound textures Actual bind(null, i) calls will be performed at next unbind() call

void
unbind(texture: PIXI.BaseTexture)

Public Properties


boundTextures TextureSystem.ts:18
boundTextures: PIXI.BaseTexture[]

Bound textures.

currentLocation TextureSystem.ts:49
currentLocation: number

Current location.

managedTextures TextureSystem.ts:24
managedTextures: Array<PIXI.BaseTexture>

List of managed textures.

Protected Properties


hasIntegerTextures TextureSystem.ts:30
protected hasIntegerTextures: boolean

Whether glTexture with int/uint sampler type was uploaded.

unknownTexture TextureSystem.ts:37
protected unknownTexture: PIXI.BaseTexture

BaseTexture value that shows that we don't know what is bound.

Public Methods


bind TextureSystem.ts:122
bind(texture: PIXI.Texture | PIXI.BaseTexture, location: number) → {void}

Bind a texture to a specific location

If you want to unbind something, please use unbind(texture) instead of bind(null, textureLocation)

Parameters:
Name Type Attributes Default Description
texture PIXI.Texture | PIXI.BaseTexture

Texture to bind

location number

<optional>

0

Location to bind at

Returns:
Type Description
void
contextChange TextureSystem.ts:75
contextChange() → {void}

Sets up the renderer context and necessary buffers.

Returns:
Type Description
void
ensureSamplerType TextureSystem.ts:230
ensureSamplerType(maxTextures: number) → {void}

Ensures that current boundTextures all have FLOAT sampler type, see PIXI.SAMPLER_TYPES for explanation.

Parameters:
Name Type Description
maxTextures number

number of locations to check

Returns:
Type Description
void
reset TextureSystem.ts:179
reset() → {void}

Resets texture location and bound textures Actual bind(null, i) calls will be performed at next unbind() call

Returns:
Type Description
void
unbind TextureSystem.ts:192
unbind(texture: PIXI.BaseTexture) → {void}

Unbind a texture.

Parameters:
Name Type Attributes Description
texture PIXI.BaseTexture

<optional>

Texture to bind

Returns:
Type Description
void

Powered by webdoc!