hmi.graphics.scenegraph
Class Skeletons

java.lang.Object
  extended by hmi.graphics.scenegraph.Skeletons

public final class Skeletons
extends Object

A Utility class for Skeleton and HAnim related operations

Author:
Job Zwiers

Constructor Summary
private Skeletons()
           
 
Method Summary
private static void alignSegment(VJoint skeletonRoot, String parentSid, String childSid, float[] vec)
           
static Map<String,String> getRenaming(String renamingList, List<GNode> rootNodes)
          Renames the sids from skeleton joint, both in skeletons and in skinned meshes.
private static void prepareBindPose(VJoint joint, float[] parentRotation)
          assuming that we have reached the current pose from a bind pose where all rotation was Id, we want to prepare a pose that can be used to set the new bind pose.
static void setHAnimPose(VJoint skeletonRoot)
          Tries to set the skeleton in the HAnim neutral pose.
static void setNeutralPoses(List<GNode> skeletonRoots, List<GSkinnedMesh> skinnedMeshList, List<GNode> roots)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Skeletons

private Skeletons()
Method Detail

getRenaming

public static Map<String,String> getRenaming(String renamingList,
                                             List<GNode> rootNodes)
Renames the sids from skeleton joint, both in skeletons and in skinned meshes. The new sid will be used both as joint sid and joint name (but not as joint id)


alignSegment

private static void alignSegment(VJoint skeletonRoot,
                                 String parentSid,
                                 String childSid,
                                 float[] vec)

setHAnimPose

public static void setHAnimPose(VJoint skeletonRoot)
Tries to set the skeleton in the HAnim neutral pose. It is assumed that joints have joint sids according to the HAnim standard. Assumes the ankles are aligned correctly for 'stable' standing, re-aligns them so that the ankle stance is maintained.


prepareBindPose

private static void prepareBindPose(VJoint joint,
                                    float[] parentRotation)
assuming that we have reached the current pose from a bind pose where all rotation was Id, we want to prepare a pose that can be used to set the new bind pose.


setNeutralPoses

public static void setNeutralPoses(List<GNode> skeletonRoots,
                                   List<GSkinnedMesh> skinnedMeshList,
                                   List<GNode> roots)