Fog can add significantly to the experience of depth within a world. You can add fog either in your script, or through Inspector.
There are four main properties for fog:
Property |
Description |
mode |
Fog can be rendered either in a linear or exponential relationship to the distance from the observer. |
color |
Sets the color of the fog. |
range |
Sets the beginning and ending distances of the fog from the observer. |
density |
Sets the density of the fog. |
You can add fog within your script using the <scene>.fog command. The fog equations used depend on the parameters supplied. If range values are given, then linear fogging is enabled in which no fog appears before start distance from the observer and 100% density is reached at end distance from the observer. If a density is given, then an exponential drop-off function is used as continuous from 0 to infinity.