Geometric transformations, like moving, scaling, rotating, and skewing, and color transformations, like tint and brightness adjustment, can be represented as matrices. When you apply successive transformations, those transformation matrices are multiplied together so that the current state of an object can be represented by a single matrix, even though it may be the result of several transformations. Flash Player gives you access to these transformations with the
flash.geom.Transform class. Using the properties of
Transform, you can manipulate an object's geometric transformation matrices and its color transformations, giving you a more computer-graphics-centric interface to geometric transforms including position, scale, rotation, translation, and skew, and enabling basic manipulation of colors.
You can always manipulate the geometry of display objects with their properties like
rotation. The transformation matrices introduced in this chapter provide a more powerful, mathematical interface to the same geometry. I hate to say it because it's so interesting, but you could consider this chapter optional.
To use transformation matrices, you'll need to understand some matrix math. In the section "Matrices and coordinates" I'll provide a brief introduction. When you get into 3D I'll provide another refresher in the section "Basic 3D concepts ...