Game Development Reference
In-Depth Information
direction we care about. Finally, we have the Lambert factor. As discussed
in Section 10.1.2, this accounts for the fact that more incident light is avail-
able to be reflected, per unit surface area, when
ω in is perpendicular to
the surface than when at a glancing angle to the surface. The vector n
is the outward-facing surface normal; the dot product −
n peaks at 1
in the perpendicular direction and trails off to zero as the angle of inci-
dence becomes more glancing. We discuss the Lambert factor once more in
Section 10.6.3.
In purely mathematical terms, the rendering equation is an integral
equation: it states a relationship between some unknown function
L out ( x ,
ω in
ω out ,λ), the distribution of light on the surfaces in the scene, in
terms of its own integral. It might not be apparent that the rendering
equation is recursive, but L out actually appears on both sides of the equals
sign. It appears in the evaluation of L in ( x ,
ω in ,λ), which is precisely the
expression we set out to solve for each pixel: what is the radiance incident
on a point from a given direction? Thus to find the radiance exiting a
point x , we need to know all the radiance incident at x from all directions.
But the radiance incident on x is the same as the radiance leaving from all
other surfaces visible to x , in the direction pointing from the other surface
towards x .
To render a scene realistically, we must solve the rendering equation,
which requires us to know (in theory) not only the radiance arriving at the
camera, but also the entire distribution of radiance in the scene in every
direction at every point. Clearly, this is too much to ask for a finite, digital
computer, since both the set of surface locations and the set of potential
incident/exiting directions are infinite. The real art in creating software for
digital image synthesis is to allocate the limited processor time and memory
most e ciently, to make the best possible approximation.
The simple rendering pipeline we present in Section 10.10 accounts only
for direct light. It doesn't account for indirect light that bounced off of
one surface and arrived at another. In other words, it only does “one
recursion level” in the rendering equation. A huge component of realistic
images is accounting for the indirect light—solving the rendering equation
more completely. The various methods for accomplishing this are known
as global illumination techniques.
This concludes our high-level presentation of how graphics works. Al-
though we admit we have not yet presented a single practical idea, we
believe it's very important to understand what you are trying to approxi-
mate before you start to approximate it. Even though the compromises we
are forced to make for the sake of real-time are quite severe, the available
computing power is growing. A video game programmer whose only expo-
sure to graphics has been OpenGL tutorials or demos made by video card
manufacturers or topics that focused exclusively on real-time rendering will
Search WWH ::




Custom Search