Class WebGlCoreShaderAbstract

Hierarchy

  • CoreShader
    • WebGlCoreShader

Constructors

Properties

attributeBuffers: Record<string, WebGLBuffer>
attributeLocations: Record<string, number>
attributeNames: string[]
boundBufferCollection: null | BufferCollection = null
buffersBound: boolean = false
glw: WebGlContextWrapper
program: WebGLProgram
supportsIndexedTextures: boolean
uniformLocations: Record<string, WebGLUniformLocation>
uniformTypes: Record<string, "uniform1f" | "uniform1i" | "uniform2f" | "uniform2i" | "uniform3f" | "uniform3i" | "uniform4f" | "uniform4i" | "uniform1fv" | "uniform1iv" | "uniform2fv" | "uniform2iv" | "uniform3fv" | "uniform3iv" | "uniform4fv" | "uniform4iv" | "uniformMatrix2fv" | "uniformMatrix3fv" | "uniformMatrix4fv">
vao: undefined | WebGLVertexArrayObject

Vertex Array Object

Remarks

Used by WebGL2 Only

shaderSources?: ShaderProgramSources

Methods

  • Given two sets of Shader props destined for this Shader, determine if they can be batched together to reduce the number of draw calls.

    Parameters

    • propsA: Record<string, unknown>
    • propsB: Record<string, unknown>

    Returns boolean

    Remarks

    This is used by the WebGlCoreRenderer to determine if it can batch multiple consecutive draw calls into a single draw call.

    By default, this returns false (meaning no batching is allowed), but can be overridden by child classes to provide more efficient batching.

  • Parameters

    • props: Record<string, unknown>

    Returns string | false

  • Parameters

    • props: Record<string, unknown>

    Returns Record<string, unknown>

Generated using TypeDoc