com.threed.jpct.skeleton
Class VertexAssignment

java.lang.Object
  extended by com.threed.jpct.skeleton.VertexAssignment

public class VertexAssignment
extends java.lang.Object

Encapsulates a vertex assignment. This class, by default, permits 4 bones, and vertex weights.

Author:
mcgreevyj

Constructor Summary
VertexAssignment()
           
 
Method Summary
 void addBone(SimpleBone bone, float weight)
          Adds a bone to the assignment array.
 boolean assignedTo(SimpleBone bone)
          Returns true if the bone has been assigned, and false if the bone is not assigned.
 boolean hasAssignedBones()
          Returns true if there are bones assigned, false otherwise.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

VertexAssignment

public VertexAssignment()
Method Detail

addBone

public void addBone(SimpleBone bone,
                    float weight)
Adds a bone to the assignment array. Maximum of 4 bones by default.

Parameters:
bone - Bone to add to list.
weight - Weight of assignment.

assignedTo

public boolean assignedTo(SimpleBone bone)
Returns true if the bone has been assigned, and false if the bone is not assigned.

Parameters:
bone - Bone to check assignment of
Returns:
True if found, false otherwise

hasAssignedBones

public boolean hasAssignedBones()
Returns true if there are bones assigned, false otherwise.

Returns:
True if bones are assigned, false otherwise