#

API Docs for: 1.6.0
Show: Inherited Protected Private Deprecated

# PixiShader Class

Defined in: `src/pixi/renderers/webgl/shaders/PixiShader.js:6`
Module: PIXI

## Constructor

### `PixiShader`

()

Defined in `src/pixi/renderers/webgl/shaders/PixiShader.js:6`

- Index
- Methods
- Properties

## Item Index

### Methods

- destroy
- init
- initSampler2D
- initUniforms
- syncUniforms

### Properties

- defaultVertexSrc
- fragmentSrc - The fragment shader.
- gl
- program - The WebGL program.
- textureCount - A local texture counter for multi-texture shaders.

## Methods

### `destroy`

()

Defined in `src/pixi/renderers/webgl/shaders/PixiShader.js:305`

Destroys the shader

### `init`

()

Defined in `src/pixi/renderers/webgl/shaders/PixiShader.js:48`

Initialises the shader

### `initSampler2D`

()

Defined in `src/pixi/renderers/webgl/shaders/PixiShader.js:173`

Initialises a Sampler2D uniform (which may only be available later on after initUniforms once the texture has loaded)

### `initUniforms`

()

Defined in `src/pixi/renderers/webgl/shaders/PixiShader.js:100`

Initialises the shader uniform values. Uniforms are specified in the GLSL_ES Specification: http://www.khronos.org/registry/webgl/specs/latest/1.0/ http://www.khronos.org/registry/gles/specs/2.0/GLSL_ES_Specification_1.0.17.pdf

### `syncUniforms`

()

Defined in `src/pixi/renderers/webgl/shaders/PixiShader.js:248`

Updates the shader uniform values.

## Properties

### `defaultVertexSrc`

String

Defined in `src/pixi/renderers/webgl/shaders/PixiShader.js:318`

The Default Vertex shader source

### `fragmentSrc - The fragment shader.`

Array

Defined in `src/pixi/renderers/webgl/shaders/PixiShader.js:25`

### `gl`

WebGLContext

Defined in `src/pixi/renderers/webgl/shaders/PixiShader.js:14`

### `program - The WebGL program.`

Any

Defined in `src/pixi/renderers/webgl/shaders/PixiShader.js:20`

### `textureCount - A local texture counter for multi-texture shaders.`

Number

Defined in `src/pixi/renderers/webgl/shaders/PixiShader.js:38`