Game Development Reference
where ( tx , ty , tz ) is the translation in the x -, y - and z -axes respectively.
This technique requires us to add a component to the vector
representation of a vertex. Now a vertex is defined as [ x , y , z , 1] T . Such
coordinates are often referred to as homogeneous coordinates. The
matrix can now include the perspective transform that converts world
coordinates into the 2D screen coordinates that the viewer ultimately
sees. By concatenating the above matrix with a matrix that achieves this
perspective transform, all the calculations necessary to take a vertex from
model space through world space to camera space and finally to screen
space can be achieved by a single matrix.
The basic operations presented here will act as building blocks as we
develop the character animation engine. To get the most out of this topic,
you need to be confident of the use of vectors, matrix multiplication and
the simple algebra manipulation we used in this chapter. I have tried to
present the material in a form that is suitable for those who are unfamiliar
with mathematical set texts. If the reader wishes to explore the
mathematics presented in this chapter in more depth, then please check
Appendix C, where further references are mentioned.