Documentation
    Preparing search index...

    Interface SpotLightSource

    A PunctualLightSourceBase with a cone — §68's spot light.

    interface SpotLightSource {
        color: readonly [number, number, number];
        innerConeAngle: number;
        intensity: number;
        isPunctualLight: true;
        lightType: "spot";
        outerConeAngle: number;
        range: number;
        getWorldDirection(out: Vector3): Vector3;
        getWorldPosition(out: Vector3): Vector3;
    }

    Hierarchy (View Summary)

    Index
    color: readonly [number, number, number]

    Straight RGB in §60a's linear-light working space (§68).

    innerConeAngle: number

    Half-angle of the fully-lit core, in radians (§7a).

    intensity: number

    Scalar multiplier on the colour: the irradiance, over π, at unit distance (§68; see @fourjs/scene's light.ts for the convention).

    isPunctualLight: true

    The brand collectSceneLights recognises. A literal true, not a method, so the check is one property load per node per frame.

    lightType: "spot"
    outerConeAngle: number

    Half-angle at which the cone reaches zero, in radians (§7a).

    range: number

    Distance at which the contribution reaches zero, or 0 for unbounded — the KHR_lights_punctual window @fourjs/scene's PunctualLight documents.

    • Writes the world-space unit vector the cone points along into out — the node's −Z axis, the same convention DirectionalLightSource uses.

      Parameters

      Returns Vector3