Game Development Reference
In-Depth Information
This is the simplest of lighting models. We have used a single normal
vector to calculate a lighting level for the entire polygon. An alternative
approach uses each vertex normal to get a lighting level for that vertex,
then interpolation between vertices when drawing the on-screen pixels.
This method is called Gouraud shading and gives a low polygon model
the illusion of a much denser mesh, where the polygons appear to be
much smoother than they really are. In our simplistic shading model we
have not considered the highlights resulting from a high level of
specularity . To achieve accurate highlights it is necessary to interpolate
between vertex normal vectors to calculate the vector for each on-screen
pixel. This model gives accurate highlights at the expense of additional
calculations and is called Phong shading.
Figure 2.7 Drawing a textured polygon.
Painting a textured polygon
When creating low polygon displays, textures play an important role.
Instead of very dense meshes, the illusion of complexity can be achieved
by replacing the diffuse colour value with the colour value of a pixel from
 
Search Nedrilad ::




Custom Search