Math used in 3D (Game) Engine Programming

Alex picture Alex · Aug 24, 2009 · Viewed 34.9k times · Source

I'd like to get an idea what kind of math is typically necessary for 3D game engine programming? Any specific math (such as vector geometry) or calculation algorithms (such as fast fourier transforms), or is this all abstracted away with DirectX/OpenGL so that highly complex math isn't really necessary any more?

Answer

Aleks picture Aleks · Jan 23, 2010

Linear Algebra! Lots of lots of Linear Algebra!

Here are just classes and example situations where you need them

  • Vector - position, velocity, normals
  • Matrix - transformations
  • Quaternion - rotations (great for bone animations)
  • Ray - projectile collision detection
  • Plane - projectile collision detection
  • Frustum - render culling
  • Sphere - render culling, fast collision test
  • Axis-Align Bounding Box - culling, collision tests, spacial partitioning
  • Oriented Bounding Box - collision tests
  • Convex Hull - collision, spacial partitioning
  • etc.

You should start with Vector and Matrix as they will be used everywhere in the engine (graphics, physics, AI, etc.)