The fl.motion package contains functions and classes to describe a motion tween (either 2D or 3D via the Animator3D class) and apply that tween to a display object. You can either reference XML or use ActionScript with arrays to describe a motion tween. Flash CS4 has Copy Motion as ActionScript 3.0 and Copy Motion as XML commands that generate ActionScript and XML based on a motion tween on the Timeline in the authoring tool. You can use the generated ActionScript to apply the animation to other display objects. You can also script your own XML and use the fl.motion classes to apply the animation to a specified display object instance. Though XML is quite efficient, it is not necessary to use it to describe motion tweens; you can instead supply arrays of property values with ActionScript commands to obtain the same effect.

For information on the supporting XML elements, see Motion XML Elements.

To learn more about scripting your own animation or editing content from the Flash CS4 Copy Motion commands, begin with the Animator and Animator3D classes which contain the primary functions and properties for applying the Motion XML or ActionScript arrays to a motion tween.



Interfaces
 InterfaceDescription
 ITweenThe ITween interface defines the application programming interface (API) that interpolation classes implement in order to work with the fl.motion classes.
Classes
 ClassDescription
 AdjustColorThe AdjustColor class defines various color properties, such as brightness, contrast, hue, and saturation, to support the ColorMatrixFilter class.
 AnimatorThe Animator class applies an XML description of a motion tween to a display object.
 Animator3DThe Animator3D class applies an XML description of a three-dimensional motion tween to a display object.
 AnimatorBaseThe AnimatorBase class applies an XML description of a motion tween to a display object.
 AnimatorFactoryThe AnimatorFactory class provides ActionScript-based support to associate one Motion object with multiple display objects.
 AnimatorFactory3DThe AnimatorFactory3D class provides ActionScript-based support to associate one Motion object containing three-dimensional properties with multiple display objects.
 AnimatorFactoryBaseThe AnimatorFactoryBase class provides ActionScript-based support to display and tween multiple targeted objects with one Motion dynamically at runtime.
 BezierEaseThe BezierEase class provides precise easing control for a motion tween between two keyframes.
 BezierSegmentA Bezier segment consists of four Point objects that define a single cubic Bezier curve.
 ColorThe Color class extends the Flash Player ColorTransform class, adding the ability to control brightness and tint.
 ColorMatrixThe ColorMatrix class calculates and stores color matrixes based on given values.
 CustomEaseThe CustomEase class is used to modify specific properties of the easing behavior of a motion tween as the tween progresses over time.
 DynamicMatrixThe DynamicMatrix class calculates and stores a matrix based on given values.
 FunctionEaseThe FunctionEase class allows custom interpolation functions to be used with the fl.motion framework in place of other interpolations like SimpleEase and CustomEase.
 KeyframeThe Keyframe class defines the visual state at a specific time in a motion tween.
 KeyframeBaseThe KeyframeBase class defines the visual state at a specific time in a motion tween.
 MatrixTransformerThe MatrixTransformer class contains methods for modifying individual properties of a transformation matrix: horizontal and vertical scale, horizontal and vertical skew, and rotation.
 MotionThe Motion class stores a keyframe animation sequence that can be applied to a visual object.
 MotionBaseThe MotionBase class stores a keyframe animation sequence that can be applied to a visual object.
 MotionEventThe MotionEvent class represents events that are broadcast by the fl.motion.Animator class.
 RotateDirectionThe RotateDirection class provides constant values for rotation behavior during a tween.
 SimpleEaseThe SimpleEase class allows you to control an animation with the kind of percentage easing that is used in the Flash timeline.
 SourceThe Source class stores information about the context in which a Motion instance was generated.
 TweenablesThe Tweenables class provides constant values for the names of animation properties used in the MotionBase and KeyframeBase classes.