Snow shader effect.

Hierarchy (View Summary)

Properties

initialUniforms: object

The initial values of the shader uniforms.

speed: number = 1

The speed multiplier applied to animation. 0 stops animation.

commonUniforms: {
    alpha: number;
    depthElevation: number;
    effectDimensions: [number, number];
    occlusionTexture: null | Texture<Resource>;
    occlusionWeights: number[];
    reverseOcclusion: boolean;
    reverseTerrain: boolean;
    screenDimensions: [number, number];
    terrainTexture: null | Texture<Resource>;
    terrainWeights: number[];
    time: number;
    tint: number[];
    useOcclusion: boolean;
    useTerrain: boolean;
} = ...

Common uniforms for all weather shaders.

COMPUTE_MASK: string = ...

Compute the weather masking value.

defaultUniforms: { direction: number } = ...

Default uniforms for a specific class

FRAGMENT_HEADER: string = ...

Compute the weather masking value.

fragmentShader: string = ...

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

vertexShader: string = ...

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

Accessors

  • set scale(scale: number | { x: number; y: number }): void

    Update the scale of this effect with new values

    Parameters

    • scale: number | { x: number; y: number }

      The desired scale

    Returns void

Methods