hmi.debug.animation
Class VJointDebugVisualisations

java.lang.Object
  extended by hmi.debug.animation.VJointDebugVisualisations

public class VJointDebugVisualisations
extends Object

Provides debug visualisations for VJoints, such as colored spheres, or small colored axis crosses that also indicate the orientation. Use this class as follows: given a VJoint vj that you want to visualize, request a debug visualisation for it. The result is a VGLNode. The VGLNode should be added to your renderlist. The VGLNode.getRoot() should be added to your WorldRenderRoot -- to make sure that its matrices are calculated whenever its needed Note: if you want to place the debug visualisation some distance away from the VJoint that it should visualise, place an extra node between the VGLNode.getRoot and WorldRenderRoot, and set the translation of that node. The resulting visualisation should follow all movements of the source VJoint vj. each type of visualisation has a variation for single VJoints, and for the whole tree. VGLNode debugViz = VJointDebugVisualisations.getColoredShapeDebugVisualisationTree(avatarRootJoint, "axis-cross"); debugVisualisations.add(debugViz); //these must be rendered every app.glRender VJoint move = new VJoint(); move.setTranslation(trans); move.addChild(debugViz.getRoot()); vjWorldRenderRoot.addChild(move); //in order to have the necessary calculatematrices called on this visualisation


Constructor Summary
VJointDebugVisualisations()
           
 
Method Summary
static VGLNode getColoredShapeDebugVisualisation(VJoint master, String type)
          place a small colored shape at each joint.
static VGLNode getColoredShapeDebugVisualisation(VJoint master, String type, ArrayList<GLRenderObject> renderStates, float size)
           
static VGLNode getColoredShapeDebugVisualisationTree(VJoint master, String type)
           
static VGLNode getColoredShapeDebugVisualisationTree(VJoint master, String type, ArrayList<GLRenderObject> renderStates, float size)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

VJointDebugVisualisations

public VJointDebugVisualisations()
Method Detail

getColoredShapeDebugVisualisation

public static VGLNode getColoredShapeDebugVisualisation(VJoint master,
                                                        String type)
place a small colored shape at each joint. size is in centimeters type gives type of shape: "none": don't draw any shape. Don't know why this would be useful... "sphere" and "box" are centered shapes in given color; "axis-cross" draws an axis cross with red in positive x, green in positive y and blue in positive z direction from (0,0,0)


getColoredShapeDebugVisualisation

public static VGLNode getColoredShapeDebugVisualisation(VJoint master,
                                                        String type,
                                                        ArrayList<GLRenderObject> renderStates,
                                                        float size)

getColoredShapeDebugVisualisationTree

public static VGLNode getColoredShapeDebugVisualisationTree(VJoint master,
                                                            String type)

getColoredShapeDebugVisualisationTree

public static VGLNode getColoredShapeDebugVisualisationTree(VJoint master,
                                                            String type,
                                                            ArrayList<GLRenderObject> renderStates,
                                                            float size)