In this chapter, we will cover the following recipes:
Implementing the per-vertex ambient light component
Implementing the per-vertex diffuse light component
Implementing the per-vertex specular light component
Optimizing the specular light with the halfway vector
Gouraud shading – the per-vertex shading technique
Phong shading – the per-fragment shading technique
Implementing directional and point light
Implementing multiple lights in a scene
Implementing two-side shading