org.jagatoo.loaders.models.cal3d.core
Class CalCoreAnimation

java.lang.Object
  extended by org.jagatoo.loaders.models.cal3d.core.CalCoreAnimation

public class CalCoreAnimation
extends java.lang.Object

The core animation class.


Field Summary
protected  float duration
           
protected  java.util.List<CalCoreTrack> listCoreTrack
           
protected  java.lang.String name
           
protected  java.lang.String resourceName
           
 
Constructor Summary
CalCoreAnimation()
          Constructs the core animation instance.
 
Method Summary
 void addCoreTrack(CalCoreTrack coreTrack)
          Adds a core track.
 CalCoreTrack getCoreTrack(int coreBoneId)
          Provides access to a core track.
 float getDuration()
          Returns the duration.
 java.util.List<CalCoreTrack> getListCoreTrack()
          Returns the core track list.
 java.lang.String getName()
           
 java.lang.String getResourceName()
           
 void removeCoreTrack(int coreBoneId)
          Removes a core track for a given bone ID - useful for pruning unwanted bones
 void scale(float factor)
          Scale the core animation.
 void setDuration(float duration)
          Sets the duration.
 void setName(java.lang.String name)
           
 void setResourceName(java.lang.String resourceName)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

name

protected java.lang.String name

resourceName

protected java.lang.String resourceName

duration

protected float duration

listCoreTrack

protected java.util.List<CalCoreTrack> listCoreTrack
Constructor Detail

CalCoreAnimation

public CalCoreAnimation()
Constructs the core animation instance. This function is the default constructor of the core animation instance.

Method Detail

addCoreTrack

public void addCoreTrack(CalCoreTrack coreTrack)
Adds a core track. This function adds a core track to the core animation instance.

Parameters:
coreTrack - A pointer to the core track that should be added.

getCoreTrack

public CalCoreTrack getCoreTrack(int coreBoneId)
Provides access to a core track. This function returns the core track for a given bone ID.

Parameters:
coreBoneId - The core bone ID of the core track that should be returned.
Returns:
the core track or null if not found

removeCoreTrack

public void removeCoreTrack(int coreBoneId)
Removes a core track for a given bone ID - useful for pruning unwanted bones


scale

public void scale(float factor)
Scale the core animation. This function rescale all the skeleton data that are in the core animation instance

Parameters:
factor - A float with the scale factor

getDuration

public float getDuration()
Returns the duration. This function returns the duration of the core animation instance.

Returns:
The duration in seconds.

getListCoreTrack

public java.util.List<CalCoreTrack> getListCoreTrack()
Returns the core track list. This function returns the list that contains all core tracks of the core animation instance.

Returns:
A reference to the core track list.

setDuration

public void setDuration(float duration)
Sets the duration. This function sets the duration of the core animation instance.

Parameters:
duration - The duration in seconds that should be set.

getName

public java.lang.String getName()

setName

public void setName(java.lang.String name)

getResourceName

public java.lang.String getResourceName()

setResourceName

public void setResourceName(java.lang.String resourceName)