Class sandy.core.data.AnimationData

Description

AnimationData Handles the data allowing to transform a Object3D instance.

Method Index

new AnimationData()
addElement(), animate(), getTotalFrames(), toString()

Constructor Detail

AnimationData

public function AnimationData()

Create a new AnimationData Instance

Method Detail

getTotalFrames

public function getTotalFrames(Void):Number

Returns the number of frames of the animation

Parameters

Void

Return

Number the number of frames of the animation

addElement

public function addElement(idFrame:Number, idVertex:Number, x:Number, y:Number, z:Number):Void

Add a frame animation for a specified vertex. The value given in parameter is the position of the vertex (not an offset).

Parameters

idFrameNumber the frame id
idVertexNumber the id of the vertex to modify
xNumber The x 3D component you want to apply to the Object3D original vertex
yNumber The y 3D component you want to apply to the Object3D original vertex
zNumber The z 3D component you want to apply to the Object3D original vertex

animate

public function animate(o:Object3D, idFrame:Number)

Modify an objet with this animator. THe object vertex will be changed to the animator positions at he specified frame.

Parameters

oObject3D The object you want to animate
idFrameNumber the frame number you want to animate the object at.

toString

public function toString(Void):String

Get a String representation of the AnimationData.

Return

A String representing the AnimationData.