Graphics Reference
In-Depth Information
Figure 16.12. The unperturbed normal (left), a small value of uNoiseAmp (middle), and a larger value of
uNoiseAmp (right).
this phenomenon in action if you lie at the botom of a swimming pool and
look up. Straight up, you will see the sky. As you look away from the straight-
up vector you will still see the sky, but at some angle (about 50˚) you will start
to see the botom of the pool relected instead. To handle this properly, we
check for that case and set the color to be what would have been reflected from
the fragment rather than refracted. Figure 16.12 shows this in action.
Atmospheric Effects
There are many wonderful effects from sunlight (and even moonlight) in the
atmosphere. In this section, we consider two effects, both caused by light inter-
acting with water droplets in the atmosphere. The rainbow is probably the most
familiar and has been important to people for all known history. The glory ,
caused by backscatering from much smaller water droplets
such as clouds (near 10 µm in diameter), was once known pri-
marily to mountain climbers because it depends on looking
at a point immediately opposite the direction of light. Now
it is most often seen when you are flying. Figure 16.13 shows
the general concept of light being refracted at the surface of
a water droplet and reflected internally within the droplet,
including the fact that this varies slightly for different wave-
lengths of light. There are many other amazing atmospheric
effects, such as halos, sunpillars, and sundogs; for a remark-
Figure 16.13. General light
backscatering process, showing
the different paths for different
wavelengths of light.
Search WWH ::




Custom Search