|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjarp.Skeleton
public class Skeleton
The bones hierarchy for a Java ARP avatar.
Nested Class Summary | |
---|---|
static interface |
Skeleton.BoneHandler
Bone visitor interface. |
Field Summary | |
---|---|
static int |
HEAD_4CC
4-cc value for HEAD bone. |
static int |
NEC1_4CC
4-cc value for NEC1 bone. |
static int |
ROOT_4CC
4-cc value for ROOT bone. |
Constructor Summary | |
---|---|
Skeleton()
Default constructor: no root, #bones==0, and an empty bones table. |
|
Skeleton(JAInputStream jins)
Reads this Skeleton from the given stream. |
|
Skeleton(JAInputStream jins,
boolean useint4cc)
Reads this Skeleton from the given stream. |
Method Summary | |
---|---|
void |
computeGlobalBoneTransforms()
Recursively sets the (global) transformation matrix for each bone in the hierarchy, using its relative TR-set, and the matrix of its parent. |
Bone |
getBone(int fourcc)
Returns the bone with the given Four-CC name. |
float |
getSkeletonYOffest()
Returns this skeleton's global Y-offset value. |
void |
save(JAOutputStream jouts)
Writes this Skeleton to the given stream. |
void |
save(JAOutputStream jouts,
boolean useint4cc)
|
void |
scanBones(Bone bone,
Skeleton.BoneHandler bhdlr)
Scans the bones hierarchy rooted at the given bone in depth-first order, using the given handler's bone visitor method. |
void |
scanBones(Skeleton.BoneHandler bhdlr)
Skeleton bones traversal: performs a depth-first traversal of the skeleton hierarchy calling the given Skeleton.BoneHandler 's visitor method for each bone. |
void |
setBones(CASTRSet[] trsets)
Sets the bones' TR-set data from the given TR-sets. |
void |
setBones(CASTRSet[] trsets,
float scale)
Sets the bones' TR-sets from those given, with the given scaling (applied to the root translation only). |
void |
setSkeletonYOffset(float offset)
Sets this skeleton's global Y-offset value. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static int ROOT_4CC
public static int HEAD_4CC
public static int NEC1_4CC
Constructor Detail |
---|
public Skeleton()
public Skeleton(JAInputStream jins) throws java.io.IOException
java.io.IOException
public Skeleton(JAInputStream jins, boolean useint4cc) throws java.io.IOException
java.io.IOException
Method Detail |
---|
public void scanBones(Skeleton.BoneHandler bhdlr)
Skeleton.BoneHandler
's visitor method for each bone.
public void scanBones(Bone bone, Skeleton.BoneHandler bhdlr)
public Bone getBone(int fourcc)
public float getSkeletonYOffest()
public void setSkeletonYOffset(float offset)
public void save(JAOutputStream jouts) throws java.io.IOException
java.io.IOException
public void save(JAOutputStream jouts, boolean useint4cc) throws java.io.IOException
java.io.IOException
public void setBones(CASTRSet[] trsets)
public void setBones(CASTRSet[] trsets, float scale)
public void computeGlobalBoneTransforms() throws JAException
JAException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |