com.threerings.opengl.model
Class Animation.Sequential

java.lang.Object
  extended by com.threerings.expr.SimpleScope
      extended by com.threerings.opengl.model.Animation.Implementation
          extended by com.threerings.opengl.model.Animation.Sequential
All Implemented Interfaces:
Scope, ScopeUpdateListener
Enclosing class:
Animation

public static class Animation.Sequential
extends Animation.Implementation

A sequential implementation.


Field Summary
protected  int _aidx
          The index of the current animation.
protected  Animation[] _animations
          The component animations.
protected  AnimationConfig.Sequential _config
          The implementation configuration.
 
Fields inherited from class com.threerings.opengl.model.Animation.Implementation
_ctx, _targetWeight, _weight, _weightRate
 
Fields inherited from class com.threerings.expr.SimpleScope
_parentScope
 
Fields inherited from interface com.threerings.expr.Scope
EPOCH, NOW
 
Constructor Summary
Animation.Sequential(GlContext ctx, Scope parentScope, AnimationConfig.Sequential config)
          Creates a new sequential implementation.
 
Method Summary
 void blendTransforms(int update)
          Blends in the influence of this animation.
 boolean hasCompleted()
          Checks whether this animation has completed.
 boolean isPlaying()
          Determines whether the animation is currently playing.
 void setConfig(AnimationConfig.Sequential config)
          (Re)configures the implementation.
 void start()
          Starts the animation.
 boolean tick(float elapsed)
          Updates this animation based on the elapsed time in seconds.
 void updateTransforms()
          Updates the transforms directly from this animation.
 
Methods inherited from class com.threerings.opengl.model.Animation.Implementation
blendToWeight, getPriority, getScopeName, setConfig, stop, stop
 
Methods inherited from class com.threerings.expr.SimpleScope
addListener, dispose, get, getParentScope, removeListener, scopeUpdated
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_config

protected AnimationConfig.Sequential _config
The implementation configuration.


_animations

protected Animation[] _animations
The component animations.


_aidx

protected int _aidx
The index of the current animation.

Constructor Detail

Animation.Sequential

public Animation.Sequential(GlContext ctx,
                            Scope parentScope,
                            AnimationConfig.Sequential config)
Creates a new sequential implementation.

Method Detail

setConfig

public void setConfig(AnimationConfig.Sequential config)
(Re)configures the implementation.


start

public void start()
Description copied from class: Animation.Implementation
Starts the animation.

Overrides:
start in class Animation.Implementation

isPlaying

public boolean isPlaying()
Description copied from class: Animation.Implementation
Determines whether the animation is currently playing.

Overrides:
isPlaying in class Animation.Implementation

tick

public boolean tick(float elapsed)
Description copied from class: Animation.Implementation
Updates this animation based on the elapsed time in seconds.

Overrides:
tick in class Animation.Implementation
Returns:
true if the animation has completed.

hasCompleted

public boolean hasCompleted()
Description copied from class: Animation.Implementation
Checks whether this animation has completed.

Overrides:
hasCompleted in class Animation.Implementation

updateTransforms

public void updateTransforms()
Description copied from class: Animation.Implementation
Updates the transforms directly from this animation.

Overrides:
updateTransforms in class Animation.Implementation

blendTransforms

public void blendTransforms(int update)
Description copied from class: Animation.Implementation
Blends in the influence of this animation.

Overrides:
blendTransforms in class Animation.Implementation
Parameters:
update - the current value of the update counter (used to determine which nodes have been touched on this update).