Further Reading

DeRose, Goldman, and their collaborators have argued for an elegant “coordinate-free” approach to describing vector geometry for graphics, where the fact that positions and directions happen to be represented by left-parenthesis x comma y comma z right-parenthesis coordinates with respect to a particular coordinate system is deemphasized and where points and vectors themselves record which coordinate system they are expressed in terms of (Goldman 1985; DeRose 1989; Mann et al. 1997). This makes it possible for a software layer to ensure that common errors like adding a vector in one coordinate system to a point in another coordinate system are transparently handled by transforming them to a common coordinate system first. We have not followed this approach in pbrt, although the principles behind this approach are well worth understanding and keeping in mind when working with coordinate systems in computer graphics.

Schneider and Eberly’s Geometric Tools for Computer Graphics is influenced by the coordinate-free approach and covers the topics of this chapter in much greater depth (Schneider and Eberly 2003). It is also full of useful geometric algorithms for graphics. A classic and more traditional introduction to the topics of this chapter is Mathematical Elements for Computer Graphics by Rogers and Adams (1990). Note that their book uses a row-vector representation of points and vectors, however, which means that our matrices would be transposed when expressed in their framework, and that they multiply points and vectors by matrices to transform them left-parenthesis normal p Subscript Baseline bold upper M right-parenthesis , rather than multiplying matrices by points as we do left-parenthesis bold upper M normal p Subscript Baseline right-parenthesis . Homogeneous coordinates were only briefly mentioned in this chapter, although they are the basis of projective geometry, where they are the foundation of many elegant algorithms. Stolfi’s book is an excellent introduction to this topic (Stolfi 1991).

There are many good books on linear algebra and vector geometry. We have found Lang (1986) and Buck (1978) to be good references on these respective topics. See also Akenine-Möller et al.’s Real-Time Rendering book (2008) for a solid graphics-based introduction to linear algebra.

The subtleties of how normal vectors are transformed were first widely understood in the graphics community after articles by Wallis (1990) and Turkowski (1990b).

Shoemake (1985) introduced quaternions to graphics and showed their utility for animating rotations. Using polar matrix decomposition for animating transformations was described by Shoemake and Duff (1992); Higham (1986) developed the algorithm for extracting the rotation from a composite rotation and scale matrix by successively adding the matrix to its inverse transpose. Shoemake’s chapters in Graphics Gems (1991, 1994, 1994) respectively give more details on the derivation of the conversion from matrices to quaternions and the implementation of polar matrix decomposition.

We followed Blow’s derivation of spherical linear interpolation (2004) in our exposition in this chapter. Bloom et al. (2004) discuss desirable properties of interpolation of rotations for animation in computer graphics and which approaches deliver which of these properties. See Eberly (2011) for a more efficient implementation of a Slerp() function, based on approximating the trigonometric functions involved with polynomials. For more sophisticated approaches to rotation interpolation, see Ramamoorthi and Barr (1997) and Buss and Fillmore (2001). A technique to efficiently compute a matrix to rotate one vector to another was presented by Akenine-Möller and Hughes (1999).

Interval arithmetic is a tool that’s often useful in rendering; see Moore’s book (1966) for a well-written introduction.

References

  1. Akenine-Möller, T., and J. Hughes. 1999. Efficiently building a matrix to rotate one vector to another. Journal of Graphics Tools 4 (4), 1–4.
  2. Akenine-Möller, T., E. Haines, and N. Hoffman. 2008. Real-Time Rendering. Natick, MA: A. K. Peters.
  3. Arvo, J. 1990. Transforming axis-aligned bounding boxes. In A. S. Glassner (Ed.), Graphics Gems I, 548–50. San Diego: Academic Press.
  4. Bloom, C., J. Blow, and C. Muratori. 2004. Errors and omissions in Marc Alexa’s “Linear combination of transformations.” www.cbloom.com/3d/techdocs/lcot_errors.pdf
  5. Blow, J. 2004. Understandling slerp, then not using it. Game Developer Magazine. Also available from number-none.com/product/Understanding Slerp, Then Not Using It
  6. Buck, R. C. 1978. Advanced Calculus. New York: McGraw-Hill.
  7. Buss, S., and J. Fillmore. 2001. Spherical averages and applications to spherical splines and interpolation. ACM Transactions on Graphics 20 (2), 95–126.
  8. DeRose, T. D. 1989. A Coordinate-Free Approach to Geometric Programming. Math for SIGGRAPH, SIGGRAPH Course Notes #23. Also available as Technical Report No. 89-09-16, Department of Computer Science and Engineering, University of Washington, Seattle.
  9. Eberly, D. A fast and accurate algorithm for computing SLERP. Journal of Graphics, GPU, and Game Tools 15 (3), 161–76.
  10. Goldman, R. 1985. Illicit expressions in vector algebra. ACM Transactions on Graphics 4 (3), 223–43.
  11. Higham, N. 1986. Computing the polar decomposition—with applications. SIAM Journal of Scientific and Statistical Computing 7 (4), 1160–74.
  12. Lang, S. 1986. An Introduction to Linear Algebra. New York: Springer-Verlag.
  13. Mann, S., N. Litke, and T. DeRose. 1997. A coordinate free geometry ADT. Research Report CS-97-15, Computer Science Department, University of Waterloo.
  14. Moore, R. E. 1966. Interval Analysis. Englewood Cliffs, New Jersey: Prentice Hall.
  15. Ramamoorthi, R., and A. Barr. 1997. Fast construction of accurate quaternion splines. In Proceedings of SIGGRAPH ’97, Computer Graphics Proceedings, Annual Conference Series, Los Angeles, 287–92.
  16. Rogers, D. F., and J. A. Adams. 1990. Mathematical Elements for Computer Graphics. New York: McGraw-Hill.
  17. Schneider, P. J., and D. H. Eberly. 2003. Geometric Tools for Computer Graphics. San Francisco: Morgan Kaufmann.
  18. Shoemake, K. 1985. Animating rotation with quaternion curves, Computer Graphics (SIGGRAPH ’85 Proceedings), Volume 19, 245–54.
  19. Shoemake, K. 1991. Quaternions and 4x4 matrices. In J. Arvo (Ed.), Graphics Gems II, 351–54. San Diego: Academic Press.
  20. Shoemake, K. 1994a. Polar matrix decomposition. In P. Heckbert (Ed.), Graphics Gems IV, 207–21. San Diego: Academic Press.
  21. Shoemake, K. 1994b. Euler angle conversion. In P. Heckbert (Ed.), Graphics Gems IV, 222–29. San Diego: Academic Press.
  22. Shoemake, K., and T. Duff. 1992. Matrix animation and polar decomposition. In Proceedings of Graphics Interface 1992, 258–64.
  23. Stolfi, J. 1991. Oriented Projective Geometry. San Diego: Academic Press.
  24. Turkowski, K. 1990b. Properties of surface-normal transformations. In A. S. Glassner (Ed.), Graphics Gems I, 539–47. San Diego: Academic Press.
  25. Wallis, B. 1990. Forms, vectors, and transforms. In A. S. Glassner (Ed.), Graphics Gems I, 533–38. San Diego: Academic Press.