Environment · interface

DaylightKey

The lighting at one point of the palette's scalar. Every colour is linear and may exceed one.

Explained in Sky and atmosphere.

interface DaylightKey
import type { DaylightKey } from '@driftengine/core';

Properties

NameTypeDescription
atreadonlynumberWhere on the palette's scalar this key sits: a sun elevation, a day factor, an hour.
sunColorreadonlyReadonly<Vec3>The sun's radiance at the surface it lights, which is the directional light while it is up.
moonColorreadonlyReadonly<Vec3>The moon's, for whichever part of the palette the moon lights.
skyTopreadonlyReadonly<Vec3>
skyHorizonreadonlyReadonly<Vec3>
skyDeepreadonlyReadonly<Vec3>
ambientreadonlyReadonly<Vec3>The hemisphere's sky half.
ambientGroundreadonlyReadonly<Vec3>The hemisphere's ground half: what the floor throws back up.
fogColorreadonlyReadonly<Vec3>
fogDensityreadonlynumber
shadowStrengthreadonlynumberHow dark a directional shadow is, 0 to 1.
emissiveGainreadonlynumberThe emissive master gain: how strongly lamps and flames read against this light.
exposurereadonlynumberThe exposure a viewer's eye settles on here. Positive; blended in stops.