Matrix (flash.geom.Matrix)
Object
|
+-flash.geom.Matrix
public class Matrix
extends Object
The flash.geom.Matrix class represents a transformation matrix that determines how to map
points from one coordinate space to another. By setting the properties of a Matrix object and
applying it to a MovieClip or BitmapData object you can perform various graphical
transformations on the object. These transformation functions include translation (x and y
repositioning), rotation, scaling, and skewing.
Together these types of transformations are knows as affine transformations. Affine
transformations preserve the straightness of lines while transforming, and parallel lines stay
parallel.
To apply a transformation matrix to a movie clip, you create a flash.geom.Transform object,
and set its Matrix property to the transformation matrix. Matrix objects are also used as
parameters of some methods, such as the
class.
A transformation matrix object is considered a 3 x 3 matrix with the following contents:
In traditional transformation matrixes the
The Matrix class can only operate in two-dimensional space so it always assumes that the
property values
and
u
effective values of the matrix are as follows:
You can get and set the values of all six of the other properties in a Matrix object:
and
.
ty
762
ActionScript classes
draw()
u
are 0.0, and that the property value
v
method of the flash.display.BitmapData
,
, and
properties provide extra capabilities.
v
w
is 1.0. In other words the
w
,
,
,
,
,
a
b
c
d
tx
Need help?
Do you have a question about the FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE and is the answer not in the manual?