cas
Class CASMorph

java.lang.Object
  extended by cas.CASMorph

public class CASMorph
extends java.lang.Object

A CASMorph defines a morph setting for a CAS animation frame. This may be a conventional "shape" (deformation) morph, or "landmark" morph defined as an (x,y) displacement of a landmark point in an appearance model. Each morph is identified by it four-cc name.


Field Summary
static int LANDMARK
           
static int SHAPE
           
 
Constructor Summary
CASMorph(CASMorph morph)
          Constructs a copy of the given morph.
CASMorph(int name4cc, float value)
          Constructs a shape morph with the given (four-cc) name and amount value.
CASMorph(int name4cc, float xx, float yy)
          Constructs a landmark morph with the given (four-cc) name and offset values.
CASMorph(JAInputStream jins)
          Constructs this morph from the given stream.
CASMorph(java.lang.String name, float value)
          Constructs a shape morph with the given name and amount value.
CASMorph(java.lang.String name, float xx, float yy)
          Constructs a landmark morph with the given name and offset values.
 
Method Summary
 float getAmount()
          Returns this morph's amount value.
 int getName()
          Returns this morph's Four-CC name.
 int getType()
          Returns this morph's type.
 float getX()
          Returns this morph's x offset.
 float getY()
          Returns this morph's y offset.
 void save(JAOutputStream jouts)
          Saves this morph's data to the given stream.
 void saveText(java.io.PrintWriter pwrtr)
          Prints a legible form of this morph on the given writer.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SHAPE

public static int SHAPE

LANDMARK

public static int LANDMARK
Constructor Detail

CASMorph

public CASMorph(java.lang.String name,
                float value)
Constructs a shape morph with the given name and amount value.


CASMorph

public CASMorph(java.lang.String name,
                float xx,
                float yy)
Constructs a landmark morph with the given name and offset values.


CASMorph

public CASMorph(int name4cc,
                float value)
Constructs a shape morph with the given (four-cc) name and amount value.


CASMorph

public CASMorph(int name4cc,
                float xx,
                float yy)
Constructs a landmark morph with the given (four-cc) name and offset values.


CASMorph

public CASMorph(CASMorph morph)
Constructs a copy of the given morph.


CASMorph

public CASMorph(JAInputStream jins)
         throws java.io.IOException
Constructs this morph from the given stream.

Throws:
java.io.IOException
Method Detail

getName

public int getName()
Returns this morph's Four-CC name.


getType

public int getType()
Returns this morph's type.


getAmount

public float getAmount()
Returns this morph's amount value.


getX

public float getX()
Returns this morph's x offset.


getY

public float getY()
Returns this morph's y offset.


save

public void save(JAOutputStream jouts)
          throws java.io.IOException
Saves this morph's data to the given stream.

Throws:
java.io.IOException

saveText

public void saveText(java.io.PrintWriter pwrtr)
Prints a legible form of this morph on the given writer.