Taos API Reference
    Preparing search index...

    Interface DeferredLightingFeatureOptions

    interface DeferredLightingFeatureOptions {
        ibl?: IblTextures;
        light?: () => DirectionalLight | null;
        shadowsEnabled?: boolean;
        shadowSoftness?: number;
        iblIntensity?: number;
        minRoughness?: number;
        multiBounceAO?: boolean;
        disableHorizonFade?: boolean;
        enableAerial?: boolean;
        aerialSunDirection?: () => { x: number; y: number; z: number };
        useSphericalHarmonics?: boolean;
        contactShadows?: ContactShadowParams | null;
        cookie?: CookieParams | null;
        shadowFilter?: "pcss" | "vsm";
        shadowVsmBlur?: number;
        shadowVsmBleed?: number;
        shadowVsmPrecision?: "auto" | "fp32" | "fp16";
    }
    Index

    Properties

    ibl?: IblTextures
    light?: () => DirectionalLight | null

    Override the light source. By default the feature reads the scene's first DirectionalLightComponent.

    shadowsEnabled?: boolean
    shadowSoftness?: number
    iblIntensity?: number
    minRoughness?: number

    Perceptual-roughness floor (Filament MIN_PERCEPTUAL_ROUGHNESS, ~0.045) — suppresses specular aliasing on smooth surfaces. Mutable at runtime.

    multiBounceAO?: boolean

    Apply screen-space AO per-lobe — multi-bounce GTAO on the diffuse term + Lagarde specular occlusion on the specular term. false reverts to the legacy flat * ao. Mutable at runtime. Default true.

    disableHorizonFade?: boolean
    enableAerial?: boolean

    Enable aerial-perspective (atmospheric Rayleigh/Mie) fog. Opt-in — default false, so a scene only gets aerial haze when it asks for it (and supplies matching params via DeferredLightingPass.setAerialAtmosphere). See DeferredLightingPass.updateLight.

    aerialSunDirection?: () => { x: number; y: number; z: number }

    Toward-sun unit vector used for aerial-perspective scattering, separate from the key light. Supply the REAL sun here in scenes whose key light swaps to moonlight at night, so the haze tracks the true sun and goes dark after sunset instead of being lit by the moon. Defaults to -light.direction.

    useSphericalHarmonics?: boolean

    Read diffuse IBL from order-3 SH coefficients (IblTextures.shBuffer) instead of the irradiance cube (the IBL_DIFFUSE_SH pass variant). Can be flipped at runtime via DeferredLightingFeature.useSphericalHarmonics (the feature lazily builds + caches both pass variants). Default false.

    contactShadows?: ContactShadowParams | null

    Screen-space contact shadows for the sun. Omit / null to disable (default). See DeferredLightingPass.setContactShadows. Mutable at runtime via DeferredLightingFeature.contactShadows.

    cookie?: CookieParams | null

    Directional light cookie (gobo) projected along the sun. Omit / null to disable (default). See DeferredLightingPass.setCookie. Mutable at runtime via DeferredLightingFeature.cookie (scroll its offset).

    shadowFilter?: "pcss" | "vsm"

    Directional shadow filtering. 'pcss' (default) is the contact-hardening depth-comparison path. 'vsm' runs DirectionalVsmPass to bake a filterable EVSM2 moment map and samples it via the Chebyshev bound — constant-cost soft edges, MSAA/mip friendly, at the cost of some light bleeding (reduced by shadowVsmBleed). Mutable at runtime.

    shadowVsmBlur?: number

    EVSM2 moment-map blur radius — scales the linear-sampling Gaussian kernel. Default 1.2; clamped to ~1.5 (past that the kernel skips texels and the edge stair-steps).

    shadowVsmBleed?: number

    EVSM2 light-bleed reduction in [0,1). Default 0.2.

    shadowVsmPrecision?: "auto" | "fp32" | "fp16"

    EVSM2 moment precision / memory trade-off — 'auto' (default), 'fp32' (rg32float, best quality), or 'fp16' (rg16float, half memory, ≈ plain VSM). See DirectionalVsmPass.create. Set at construction.