Class Shader

A function which runs on the GPU.

Hierarchy

  • Shader

Constructors

Properties

Accessors

Methods

Constructors

  • Creates a shader from source code.

    Parameters

    • gl: WebGL2RenderingContext
    • type: ShaderType

      The type of the shader.

    • source: string

      The source code of the shader.

    Returns Shader

Properties

gl: WebGL2RenderingContext

The rendering context of this shader.

shader: WebGLShader

The WebGL API interface of this shader.

source: string

The source code of this shader.

The type of this shader.

Accessors

  • get compileStatus(): boolean
  • Whether the last shader compilation was successful.

    Returns boolean

  • get deleteStatus(): boolean
  • Whether this shader is flagged for deletion.

    Returns boolean

Methods

Generated using TypeDoc