Setting the Scene with OpenGL
You’ve come quite far with OpenGL, having learned how to render and manipulate objects in a 3D scene. In this chapter, we will cover lighting in more detail and introduce you to other OpenGL features that will help you to add polish to your game.
I introduced you to OpenGL’s lighting capabilities in Chapter 7, but glossed over some of the details. In this section, we will explore how to work with lights and use them to add greater realism to a 3D scene.
OpenGL uses the normals that you assign to the vertices or faces of a model to calculate the color of light that will be seen by ...