Package | fl.motion |
Class | public class FunctionEase |
Inheritance | FunctionEase Object |
Implements | ITween |
Language Version: | ActionScript 3.0 |
Product Version: | Flash CS3 |
Runtime Versions: | Flash Player 9.0.28.0, AIR 1.0 |
Related API Elements
Property | Defined By | ||
---|---|---|---|
constructor : Object
A reference to the class object or constructor function for a given object instance. | Object | ||
easingFunction : Function = null
A reference to a function with a (t, b, c, d) signature like
the methods in the fl.motion.easing classes. | FunctionEase | ||
functionName : String
The fully qualified name of an easing function, such as fl.motion.easing.Bounce.easeOut(). | FunctionEase | ||
parameters : Array = null
An optional array of values to be passed to the easing function as additional arguments. | FunctionEase | ||
prototype : Object [static]
A reference to the prototype object of a class or function object. | Object | ||
target : String
The name of the animation property to target. | FunctionEase |
Method | Defined By | ||
---|---|---|---|
FunctionEase(xml:XML = null)
Constructor for FunctionEase instances. | FunctionEase | ||
Calculates an interpolated value for a numerical property of animation,
using the specified easing function. | FunctionEase | ||
Indicates whether an object has a specified property defined. | Object | ||
Indicates whether an instance of the Object class is in the prototype chain of the object specified
as the parameter. | Object | ||
Indicates whether the specified property exists and is enumerable. | Object | ||
Sets the availability of a dynamic property for loop operations. | Object | ||
Returns the string representation of this object, formatted according to locale-specific conventions. | Object | ||
Returns the string representation of the specified object. | Object | ||
Returns the primitive value of the specified object. | Object |
easingFunction | property |
public var easingFunction:Function = null
Language Version: | ActionScript 3.0 |
Product Version: | Flash CS3 |
Runtime Versions: | Flash Player 9.0.28.0, AIR 1.0 |
A reference to a function with a (t, b, c, d)
signature like
the methods in the fl.motion.easing classes.
Related API Elements
functionName | property |
functionName:String
Language Version: | ActionScript 3.0 |
Product Version: | Flash CS3 |
Runtime Versions: | Flash Player 9.0.28.0, AIR 1.0 |
The fully qualified name of an easing function, such as fl.motion.easing.Bounce.easeOut()
.
The function must be a method of a class (Bounce, Cubic, Elastic, another class).
If Flash Player cannot find the class, an exception is thrown.
Implementation
public function get functionName():String
public function set functionName(value:String):void
Related API Elements
parameters | property |
public var parameters:Array = null
Language Version: | ActionScript 3.0 |
Product Version: | Flash CS3 |
Runtime Versions: | Flash Player 9.0.28.0, AIR 1.0 |
An optional array of values to be passed to the easing function as additional arguments.
target | property |
FunctionEase | () | Constructor |
getValue | () | method |
public function getValue(time:Number, begin:Number, change:Number, duration:Number):Number
Language Version: | ActionScript 3.0 |
Product Version: | Flash CS3 |
Runtime Versions: | Flash Player 9.0.28.0, AIR 1.0 |
Calculates an interpolated value for a numerical property of animation,
using the specified easing function.
If the parameters
array has been set beforehand,
those values will be passed to the easing function in addition to the
time, begin, change, and duration values.
Parameters
time:Number — The time value, which must lie between 0 and duration , inclusive.
You can choose any unit (for example, frames, seconds, milliseconds),
but your choice must match the duration unit.
| |
begin:Number — The value of the animation property at the start of the tween, when time is 0.
| |
change:Number — The change in the value of the animation property over the course of the tween.
The value can be positive or negative. For example, if an object rotates from 90 to 60 degrees, the change is -30.
| |
duration:Number — The length of time for the tween. Must be greater than zero.
You can choose any unit (for example, frames, seconds, milliseconds),
but your choice must match the time unit.
|
Number — The interpolated value at the specified time.
|
import fl.motion.Animator; //// These two lines must be added to use <FunctionEase> import fl.motion.easing.*; // import the easing classes fl.motion.easing.Back; // add a reference to every easing class you want to use //// var mc2_xml:XML = <Motion duration="30" xmlns="fl.motion.*" xmlns:geom="flash.geom.*" xmlns:filters="flash.filters.*"> <source> <Source frameRate="30" x="85.05" y="90.05" scaleX="0.999" scaleY="0.999" rotation="0" elementType="movie clip" instanceName="mc2" symbolName="BoxSymbol" linkageID="Box" class="Box"> <dimensions> <geom:Rectangle left="-39" top="-52" width="77" height="97"/> </dimensions> <transformationPoint> <geom:Point x="0.5019480519480519" y="0.5010309278350515"/> </transformationPoint> </Source> </source> <Keyframe index="0"> <tweens> <FunctionEase functionName="fl.motion.easing.Back.easeInOut"/> </tweens> </Keyframe> <Keyframe index="29" x="330" y="0"/> </Motion>; var mc2_animator:Animator = new Animator(mc2_xml, mc2); mc2_animator.play();
Mon Nov 28 2011, 06:48 AM -08:00