hex-world
    Preparing search index...

    Interface SkyDomeOptions

    interface SkyDomeOptions {
        segments?: number;
        radiusScale?: number;
        zenithColor?: ColorRepresentation;
        horizonColor?: ColorRepresentation;
        groundColor?: ColorRepresentation;
        groundDarken?: number;
        horizonFalloff?: number;
        groundFalloff?: number;
        groundTint?: ColorRepresentation;
        groundTintStrength?: number;
        sunGlow?: number;
        moonGlow?: number;
        sunSize?: number;
        moonSize?: number;
        stars?: boolean;
        starDensity?: number;
        overcastColor?: ColorRepresentation;
        fog?: false | AtmosphereOptions;
        materials?: () => Iterable<Material<MaterialEventMap> | null | undefined>;
    }
    Index

    Properties

    segments?: number

    Longitudinal sphere segments (half as many latitudinal). Default 32.

    radiusScale?: number

    Dome radius as a fraction of the camera's far plane. Default 0.45.

    zenithColor?: ColorRepresentation

    Color straight overhead. Default 0x3f74c0 (a deeper blue than the horizon).

    horizonColor?: ColorRepresentation

    Color at the horizon — also the color terrain hazes into. Default 0x8fb2d9.

    groundColor?: ColorRepresentation

    Color below the horizon. Omit to derive it from the horizon color darkened by SkyDomeOptions.groundDarken, which keeps the two in step as the day/night cycle recolors the sky.

    groundDarken?: number

    Multiplier for the derived below-horizon color. Default 0.7.

    horizonFalloff?: number

    Exponent shaping the horizon→zenith ramp. Below 1 the horizon band is wide and hazy; above 1 the deep sky reaches almost down to the ground. Default 0.62.

    groundFalloff?: number

    How far below the horizon the ground color takes over. Default 0.35.

    groundTint?: ColorRepresentation

    Haze color the horizon band is blended toward — the biome's own palette, so a desert map hazes sandy and a tundra map hazes pale grey. Derive one with averageTerrainColor. Default: none.

    groundTintStrength?: number

    How much of SkyDomeOptions.groundTint reaches the horizon. Default 0.28.

    sunGlow?: number

    Sun halo/disc strength in full day. Default 0.5.

    moonGlow?: number

    Moon halo/disc strength at night. Default 0.2.

    sunSize?: number

    Angular size of the sun disc (1 − cos θ). Default 0.0022 (~3.8°).

    moonSize?: number

    Angular size of the moon disc. Default 0.0012 (~2.8°).

    stars?: boolean

    Draw the star field at night. Default true.

    starDensity?: number

    Star lattice frequency — higher is denser and finer. Default 220.

    overcastColor?: ColorRepresentation

    Flat color an overcast sky collapses toward. Default 0x9aa3ad.

    fog?: false | AtmosphereOptions

    Distance haze on the world's surface materials, matched to the horizon color every time the sky recolors. false disables it (dome only); an options object overrides near/far/density. Requires SkyDomeOptions.materials.

    materials?: () => Iterable<Material<MaterialEventMap> | null | undefined>

    Provider for the materials that carry the atmosphere uniforms — the library's own surface shaders (terrain, roads, every liquid layer) plus any stock material you ran through attachAtmosphere. A function, not a snapshot, so swapped materials are picked up — pass () => world.hazeMaterials() style accessors and call SkyDome.refresh after a swap.

    Note there is deliberately no scene.fog hook: three's fog mixes before tone mapping and output encoding, which lands the same haze color far brighter than the library's shaders do. attachAtmosphere is the way to bring a stock material in.