Chapter 4Basic Transformations: A Vector/Matrix Primer
What You’ll Learn in this Chapter:
• What a vector is, and why you should care
• What a matrix is, and why you should care more
• How we use matrices and vectors to move geometry around
• The OpenGL conventions of the modelview and projection matrices
• What a camera is, and how to apply its transformation
• How to transform a point lights position into eye coordinates
In Chapter 3, “Basic Rendering,” you learned how to draw points, lines, and triangles in 3D. To turn a collection of shapes into a coherent scene, you must arrange them in relation to one another and to the viewer. In this chapter, you start moving shapes and objects around in your coordinate system. ...
Get OpenGL SuperBible: Comprehensive Tutorial and Reference, Fifth Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.