Documentation / Node reference / mat nodes
mat/Sky
A daylight sky, evaluated per pixel on a dome around the camera.
Mesh
Put this on a large sphere that encloses the camera and turn shadow casting off on that object. The colour of every pixel comes from the Preetham daylight model, computed from the direction you are looking and the sun position you set here, so the sky changes as you move the sun rather than being an image someone painted. It draws at the far plane, behind everything else. sides already defaults to BACK, since the dome is seen from the inside. tex/Sky bakes the same formula into a texture if you need it as an environment map instead.
Parameters
| Name | Type | What it does |
|---|---|---|
| sunElevation | Float | How high the sun sits, in degrees above the horizon. 90 is straight overhead and 0 puts it on the horizon for a sunset. Negative values drop it below the horizon and give you twilight, then night. |
| sunAzimuth | Float | Which way the sun sits, in degrees around the Y axis, measured from +Z toward +X. It decides which side of your scene is lit and where the sunset happens, but not how bright the sky is. |
| turbidity | Float | How much haze is in the air. Around 2 is a clear day with a deep blue sky and a small crisp sun. Higher values scatter more light, washing the blue toward white and spreading a bright halo around the sun, up to about 10 for thick industrial haze. |
| exposure | Float | A plain multiplier on the model's output. The daylight model works in real photometric units, which are far brighter than a screen can show, so this is what brings the result into a range you can look at. Raise it for a brighter sky, lower it for a darker one. |
| sunDisc | Bool | Whether the sun itself is drawn as a bright disc in the sky. Off keeps the sky gradient and the glow around the sun but removes the disc, which is what you want when a separate light or a lens effect stands in for it. |
| sides | UInt8 FRONT · BACK · BOTH | Which side of each triangle is drawn. FRONT draws the outward-facing side only, which is what a closed mesh wants: its inner surface is hidden anyway, so drawing it is wasted work. BACK draws the inward-facing side, for a surface seen from the inside such as a skydome or a box the camera sits in. BOTH draws either side, which is what an open single surface needs: a cutout leaf, a sheet of cloth, or a plane the camera can walk around, all of which disappear from one side under FRONT. The shadow pass follows BOTH so an open surface still casts a shadow whichever way it faces the light, and draws FRONT otherwise. |
This page is generated from the engine, so it describes the release you can download. The same text is in the editor's Help panel next to the node itself.