PIXI.Program

class Program

Helper class to create a shader program.

Constructor


new PIXI.Program(vertexSrc: string, fragmentSrc: string, name: string) → {}
Parameters:
Name Type Attributes Default Description
vertexSrc string

<optional>

The source of the vertex shader.

fragmentSrc string

<optional>

The source of the fragment shader.

name string 'pixi-shader'

Name for shader

Summary


Properties from Program

string
static defaultFragmentSrc
string
static defaultVertexSrc
{ [key: string]: IAttributeData }
attributeData

Assigned when a program is first bound to the shader system.

string
fragmentSrc

Source code for the fragment shader.

{ [key: string]: IUniformData }
uniformData

Assigned when a program is first bound to the shader system.

string
vertexSrc

Source code for the vertex shader.

Methods from Program

PIXI.Program
static from(vertexSrc: string, fragmentSrc: string, name: string)

A short hand function to create a program based of a vertex and fragment shader.

Public Properties


defaultFragmentSrc Program.ts:108
static defaultFragmentSrc: string

The default fragment shader source.

defaultVertexSrc Program.ts:99
static defaultVertexSrc: string

The default vertex shader source.

attributeData Program.ts:51
attributeData: { [key: string]: IAttributeData }

Assigned when a program is first bound to the shader system.

fragmentSrc Program.ts:44
fragmentSrc: string

Source code for the fragment shader.

uniformData Program.ts:54
uniformData: { [key: string]: IUniformData }

Assigned when a program is first bound to the shader system.

vertexSrc Program.ts:41
vertexSrc: string

Source code for the vertex shader.

Public Methods


from Program.ts:117
static from(vertexSrc: string, fragmentSrc: string, name: string) → {PIXI.Program}

A short hand function to create a program based of a vertex and fragment shader.

This method will also check to see if there is a cached program.

Parameters:
Name Type Attributes Description
vertexSrc string

<optional>

The source of the vertex shader.

fragmentSrc string

<optional>

The source of the fragment shader.

name string

<optional>

Name for shader

Returns:
Type Description
PIXI.Program

A shiny new PixiJS shader program!


Powered by webdoc!