![MACROMEDIA FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE Reference Download Page 762](http://html.mh-extra.com/html/macromedia/flash-8-actionscript-2-0-language/flash-8-actionscript-2-0-language_reference_687537762.webp)
762
ActionScript classes
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
draw()
method of the flash.display.BitmapData
class.
A transformation matrix object is considered a 3 x 3 matrix with the following contents:
In traditional transformation matrixes the
u
,
v
, and
w
properties provide extra capabilities.
The Matrix class can only operate in two-dimensional space so it always assumes that the
property values
u
and
v
are 0.0, and that the property value
w
is 1.0. In other words the
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:
a
,
b
,
c
,
d
,
tx
,
and
ty
.
Summary of Contents for FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE
Page 1: ...ActionScript 2 0 Language Reference ...
Page 1352: ...1352 ActionScript classes ...