Chapter 2. A 3D/Math Primer
This chapter is an introduction to the mathematics behind 3D graphics. And in the immortal words of Douglas Adams (of Hitchhiker’s Guide to the Galaxy), “DON’T PANIC!” We discuss vectors, matrices, coordinate systems, transformations, and the DirectX Math library. Even if linear algebra is old hat to you, we encourage you to review the material specific to DirectX. Otherwise, take a deep breath, hold on, and don’t forget your towel.
You might recall the definitions of scalars and vectors from your high school physics class. Scalars are quantities with just a magnitude (a numerical value); vectors are quantities described by both magnitude and direction. Vectors wear multiple hats in 3D graphics—they describe ...