fi.hut.tml.xsmiles.mlfc.smil.extension
Interface AnimatedValue

All Known Implementing Classes:
AnimatedColorValue, AnimatedIntegerValue, AnimatedPairValue

public interface AnimatedValue

Abstract Animated Value. Types to be animated must implement this.


Method Summary
 AnimatedValue add(AnimatedValue val)
          Add val to this.
 void clampValue()
           
 float distance(AnimatedValue val)
          Calculates the distance between this and val.
 AnimatedValue interpolate(AnimatedValue val, float t)
          Interpolate between this and val by t, where t is [0,1].
 AnimatedValue mult(int integer)
          Multiply this by integer value.
 java.lang.String toString()
          Parse this string into value.
 

Method Detail

toString

public java.lang.String toString()
Parse this string into value. Throws NumberFormatException, if cannot parse.

Returns:
Parsed AnimatedValue

clampValue

public void clampValue()

add

public AnimatedValue add(AnimatedValue val)
Add val to this.

Parameters:
val - Val to be added to this.
Returns:
Returns val+this.

mult

public AnimatedValue mult(int integer)
Multiply this by integer value.

Parameters:
integer - Integer value
Returns:
Returns this * integer.

interpolate

public AnimatedValue interpolate(AnimatedValue val,
                                 float t)
Interpolate between this and val by t, where t is [0,1]. For integers: (val-this)*t.

Parameters:
val - AnimatedValue
Returns:
Returns this * integer.

distance

public float distance(AnimatedValue val)
Calculates the distance between this and val. (for one dimension: abs(this-val) )

Parameters:
val - AnimatedValue
Returns:
Returns distance between this nad val..


X-Smiles 1.2