CS 7650: Realistic Image Synthesis
Thiago Ize
Rayleigh Scattering Participating Media
I wanted everything to be as realistic as possible (within reason of course)
instead of just pulling numbers out of a hat, so I modeled the earth and the
atmosphere as concentric spheres with roughly the correct dimensions, I
made the sun have the right size and distance, and I placed
the camera 10 meters above the ground (note that because of the precision of
doubles and my epsilon value being fixed to 1e-10,
the units I used were Mm (mega meters)). I modeled the spectral emissions
of the sun to a rough approximation (I used only 4 sample points), but it's
good enough to fool me. Oh, and because I'm lazy and haven't bothered to
implement any point sampling code for a sphere yet, the sun is currently a
square...
I've also gone ahead and added Mie Scattering. Mie Scattering is
used to model the larger particles in the air.
In the following images, the camera is pointing up at a 45 degree angle and with a 91 degree field
of view, so you can see a sliver of the earth at the bottom and the sun at the
top. The sun looks small because of the perspective distortion.