threejs-worldgen
    Preparing search index...

    Function applyNightLights

    • Copies options into the uniforms.

      Parameters

      • u: {
            color: UniformNode<"vec3", Vector3>;
            density: UniformNode<"float", number>;
            intensity: UniformNode<"float", number>;
            map: TextureNode<"vec4">;
            planetRadius: UniformNode<"float", number>;
            scale: UniformNode<"float", number>;
            twilight: UniformNode<"vec3", Vector3>;
            useTexture: UniformNode<"float", number>;
        }
        • color: UniformNode<"vec3", Vector3>

          Light colour (linear).

        • density: UniformNode<"float", number>

          Procedural coverage.

        • intensity: UniformNode<"float", number>

          Radiance of fully lit areas (0 = off).

        • map: TextureNode<"vec4">

          Lights texture (equirectangular).

        • planetRadius: UniformNode<"float", number>

          Planet radius, metres (sets the size of the sparkle).

        • scale: UniformNode<"float", number>

          Procedural feature scale.

        • twilight: UniformNode<"vec3", Vector3>

          Sun-elevation sines where lights switch on (start, full).

        • useTexture: UniformNode<"float", number>

          1 = use the texture, 0 = procedural.

      • o: NightLightsOptions

      Returns void