The transform ClassThe TRansform class allows you to collect information about color transformations and matrixes applied to movie clips. It is important that when using this class to import it first at the beginning of your script like this: import flash.geom.Transform; To instantiate a new instance of the transform class, use this code as a template: var myTrans:Transform = new Transform(mc);
PropertiescolorTransformAvailability: FP:8, AS:1.0 Generic Template: mytrans.colorTransform; Description: This property is a ColorTransform object used to adjust colors of movie clips. Example: This example will create a new instance of the transform object and send it to the Output panel:
concatenatedColorTransformAvailability: FP:8, AS:1.0 Generic Template: mytrans.concatenatedColorTransform; Description: This property is the combined ColorTransform objects used to adjust colors of movie clips. Example: This example will create a new instance of the transform object, set its color transform, and output it:
concatenatedMatrixAvailability: FP:8, AS:1.0 Generic Template: mytrans.concatenatedMatrix; Description: This property is the combined Matrix objects used to adjust positions of movie clips. Example: This example will create a new instance of the transform object, set its matrix, and output it:
matrixAvailability: FP:8, AS:1.0 Generic Template: myTRans.matrix; Description: This property is the Matrix object used to adjust positions of movie clips. Example: This example will create a new instance of the TRansform object and output its matrix property: import flash.geom.Transform; var trans:Transform = new Transform(this); trace(trans.matrix); //output: (a=1, b=0, c=0, d=1, tx=0, ty=0) pixelBoundsAvailability: FP:8, AS:1.0 Generic Template: myTRans.pixelBounds; Description: Defines the bounding rectangle of the movie clip being used. Example: This example will create a new instance of the transform object and output its pixelBounds property: import flash.geom.Transform; var trans:Transform = new Transform(this); trace(trans.pixelBounds); //output: (x=33554431, y=33554431, w=0, h=0) |