Shader specialized in wave like senses (tremorsenses)

Hierarchy (View Summary)

Properties

initialUniforms: object

The initial values of the shader uniforms.

COMPUTE_ILLUMINATION: string = ...

Compute illumination uniforms

CONSTANTS: string = ...
CONTRAST: string = ...

Contrast adjustment

defaultUniforms: {
    ambientBrightest: number[];
    ambientDarkness: number[];
    ambientDaylight: number[];
    attenuation: number;
    brightLevelCorrection: number;
    colorBackground: number[];
    colorTint: number[];
    colorVision: number[];
    contrast: number;
    darknessLevel: number;
    darknessLevelTexture: null;
    depthElevation: number;
    depthTexture: null;
    dimLevelCorrection: number;
    exposure: number;
    globalLight: boolean;
    globalLightThresholds: number[];
    linkedToDarknessLevel: boolean;
    primaryTexture: null;
    saturation: number;
    screenDimensions: number[];
    technique: number;
    time: number;
    useSampler: boolean;
    weights: number[];
} = ...

The default uniform values for the shader. A subclass of AbstractBaseShader must implement the defaultUniforms static field.

EXPOSURE: string = ...
FALLOFF: string = ...

Incorporate falloff if a attenuation uniform is requested

forceDefaultColor: boolean = false

Has this lighting shader a forced default color?

FRAGMENT_BEGIN: string = ...
FRAGMENT_END: string = ...

Shader final

FRAGMENT_FUNCTIONS: string = ...

Common functions used by the fragment shaders.

FRAGMENT_UNIFORMS: string = ...

Common uniforms shared by fragment shaders.

fragmentShader: string = ...

The raw fragment shader used by this class. A subclass of AbstractBaseShader must implement the fragmentShader static field.

SATURATION: string = ...

Saturation adjustment

SHADER_HEADER: string = ...

Memory allocations for the Adaptive Background Shader

SHADER_TECHNIQUES: Record<string, ShaderTechnique> = ...

A mapping of available shader techniques

SHADOW: string = ""
SWITCH_COLOR: string = ...

Switch between an inner and outer color, by comparing distance from center to ratio Apply a strong gradient between the two areas if attenuation uniform is set to true

TRANSITION: string = ...

Transition between bright and dim colors, if requested

VERTEX_ATTRIBUTES: string = ...

Common attributes for vertex shaders.

VERTEX_FRAGMENT_VARYINGS: string = ...

Common varyings shared by vertex and fragment shaders.

VERTEX_FUNCTIONS: string = ""

Common functions used by the vertex shaders.

VERTEX_UNIFORMS: string = ...

Common uniforms for vertex shaders.

vertexShader: string = ...

The raw vertex shader used by this class. A subclass of AbstractBaseShader must implement the vertexShader static field.

Accessors

  • get isRequired(): boolean

    Flag whether the background shader is currently required. If key uniforms are at their default values, we don't need to render the background container.

    Returns boolean

  • get ADJUSTMENTS(): string

    The adjustments made into fragment shaders

    Returns string

  • get BACKGROUND_TECHNIQUES(): string

    The coloration technique background shader fragment

    Returns string

  • get COLORATION_TECHNIQUES(): string

    The coloration technique coloration shader fragment

    Returns string

  • get ILLUMINATION_TECHNIQUES(): string

    The coloration technique illumination shader fragment

    Returns string

Methods

  • Protected

    Perform operations which are required before binding the Shader to the Renderer.

    Parameters

    • mesh: DisplayObject

      The mesh display object linked to this shader.

    • renderer: Renderer

      The renderer

    Returns void

  • Construct adaptive shader according to shader type

    Parameters

    • shaderType: string

      shader type to construct : coloration, illumination, background, etc.

    Returns string

    the constructed shader adaptive block