NatureGL Skyv1.1.0

Reference

Sky parameters

SkyParams is the whole sky as one JSON-safe object. Presets are partial SkyParams, setParams merges into them, and getParams prints the complete set.

js
sky.params;                        // the targets (what presets and setParams write)
sky.current;                       // the eased values actually being rendered
sky.setParams({ haze: 0.3 });      // partial, eased
sky.setParams({ haze: 0.3 }, { immediate: true });
sky.getParams();                   // complete copy, numbers rounded to 3 decimals, no `view`

#Clouds

KeyRangeDefault
cloudFormcumulus, altocumulus, towering, cirrus, noctilucent, cumulonimbuscumulusSee cloud forms
humidity0 – 10.5Cover and cirrus amount
coverage−1 – 10Extra coverage on top of humidity
precipitation0 – 10Dark bases, rain veils, gloom; lightning above 0.4
temperature0 – 10.45Base altitude and vertical growth
density0 – 10.55Extinction
edge0 – 10.58Erosion strength, for crisper edges
clump0 – 10.5Weather map: km-scale clumps and clearings
cirrus0 – 21Cirrus multiplier
wind0 – 10.35Drift speed
windDirectiondegrees293World azimuth the clouds drift toward
lightning0 – 110 disables lightning

#Atmosphere and light

KeyRangeDefault
haze0 – 10.14Extra aerosol: milkier sky, redder sunsets, hazier distance
exposureEV0Offset on the auto exposure
sunSize×1Sun disc size
moonSize×1Moon disc size
stars×1Star brightness
groundColorlinear RGB[0.09, 0.1, 0.08]Albedo of the ground model below the horizon

#Time and place

KeyRangeDefault
timeOfDay0 – 2415.95Hours
northOffsetdegrees112.58World azimuth of north: rotates sun, moon and stars
latitudedegrees34
declination−23.4 – 23.411Solar declination (season)
lunarAge0 – 29.5318.3Days since new moon

#Post pass

Only read when a post pass is rendering.

KeyRangeDefault
fogDensity×1Fog multiplier (0 disables)
godRays0 – 20.6Volumetric shaft strength
bloom0 – 10.3Bloom
shafts0 – 10.3Radial sun shafts

#Demo only

Key
view{ yaw?, pitch?, faceMoon? }A framing hint used by the demo; the library ignores it