AlphaAnimation

AlphaAnimation

The ‘AlphaAnimation’ class animates the ‘alpha’ property of a display object.  The benefit of using this animation type over the generic ‘PropertyAnimation’ is that the display object’s ‘visible’ property will be set to ‘false’ if it’s alpha is animated to ‘0’.  This is much more efficient than simply letting the display object be rendered with no alpha because the Flash Player will actually stop rendering the display object.

See Also

com.boostworthy.animation.management.types.PropertyAnimation, com.boostworthy.animation.management.types.abstract.Animation, com.boostworthy.animation.management.types.abstract.IAnimation

Summary
AlphaAnimationThe ‘AlphaAnimation’ class animates the ‘alpha’ property of a display object.
Constants
PROPERTYMeta data for representing the property being animated.
Variables
m_nStartValueHolds the starting value for the property being animated.
m_nTargetValueHolds the target value for the property being animated.
m_nChangeValueHolds the change in value for the property being animated.
m_nDurationHolds the duration of the animation in milliseconds.
m_nStartTimeHolds the starting time of the animation in milliseconds.
m_fncTransitionHolds a reference to the transition function being used for this animation.
Functions
AlphaAnimationConstructor.
renderRenders the animation.

Constants

PROPERTY

public static const PROPERTY: String

Meta data for representing the property being animated.

Variables

m_nStartValue

protected var m_nStartValue: Number

Holds the starting value for the property being animated.

m_nTargetValue

protected var m_nTargetValue: Number

Holds the target value for the property being animated.

m_nChangeValue

protected var m_nChangeValue: Number

Holds the change in value for the property being animated.

m_nDuration

protected var m_nDuration: Number

Holds the duration of the animation in milliseconds.

m_nStartTime

protected var m_nStartTime: Number

Holds the starting time of the animation in milliseconds.

m_fncTransition

protected var m_fncTransition: Function

Holds a reference to the transition function being used for this animation.

Functions

AlphaAnimation

public function AlphaAnimation(objTarget: DisplayObject,
nTargetValue: Number,
nDuration: Number,
strTransition: String,
uRenderMethod: uint)

Constructor.

Parameters

param objTarget The target object being animated.
param nTargetValue The value the property is getting animated to.
param nDuration The duration of the animation in milliseconds.
param strTransition The transition to be used for the animation.
param uRenderMethod The method being used to render this animation. 

See Also

com.boostworthy.animation.Transitions, com.boostworthy.animation.RenderMethod

render

public override function render():Boolean

Renders the animation.

Returns

A boolean value that is ‘true’ if the animation was updated successfully, ‘false’ if it was not. 

The ‘Animation’ class is the base class for all animation objects.
public static const PROPERTY: String
Meta data for representing the property being animated.
protected var m_nStartValue: Number
Holds the starting value for the property being animated.
protected var m_nTargetValue: Number
Holds the target value for the property being animated.
protected var m_nChangeValue: Number
Holds the change in value for the property being animated.
protected var m_nDuration: Number
Holds the duration of the animation in milliseconds.
protected var m_nStartTime: Number
Holds the starting time of the animation in milliseconds.
protected var m_fncTransition: Function
Holds a reference to the transition function being used for this animation.
public function AlphaAnimation(objTarget: DisplayObject,
nTargetValue: Number,
nDuration: Number,
strTransition: String,
uRenderMethod: uint)
Constructor.
public override function render():Boolean
Renders the animation.
Close