|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jme3.scene.plugins.blender.AbstractBlenderHelper
com.jme3.scene.plugins.blender.animations.ArmatureHelper
public class ArmatureHelper
This class defines the methods to calculate certain aspects of animation and armature functionalities.
Field Summary |
---|
Fields inherited from class com.jme3.scene.plugins.blender.AbstractBlenderHelper |
---|
blenderVersion, fixUpAxis, upAxisRotationQuaternion |
Constructor Summary | |
---|---|
ArmatureHelper(java.lang.String blenderVersion,
boolean fixUpAxis)
This constructor parses the given blender version and stores the result. |
Method Summary | |
---|---|
void |
buildBones(Structure boneStructure,
Bone parent,
java.util.List<Bone> result,
Matrix4f arbt,
java.util.Map<java.lang.Long,Structure> bonesPoseChannels,
BlenderContext blenderContext)
This method builds the object's bones structure. |
java.lang.Long |
getBoneOMA(Bone bone)
This method returns the old memory address of a bone. |
java.util.Map<java.lang.Integer,java.lang.Integer> |
getGroupToBoneIndexMap(Structure defBaseStructure,
Skeleton skeleton,
BlenderContext blenderContext)
This method returns a map where the key is the object's group index that is used by a bone and the key is the bone index in the armature. |
BoneTrack[] |
getTracks(Structure actionStructure,
Skeleton skeleton,
BlenderContext blenderContext)
This method retuns the bone tracks for animation. |
boolean |
shouldBeLoaded(Structure structure,
BlenderContext blenderContext)
This method analyzes the given structure and the data contained within blender context and decides if the feature should be loaded. |
Methods inherited from class com.jme3.scene.plugins.blender.AbstractBlenderHelper |
---|
applyProperties, clearState, isBlank, loadProperties |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ArmatureHelper(java.lang.String blenderVersion, boolean fixUpAxis)
blenderVersion
- the version read from the blend filefixUpAxis
- a variable that indicates if the Y asxis is the UP axis or notMethod Detail |
---|
public void buildBones(Structure boneStructure, Bone parent, java.util.List<Bone> result, Matrix4f arbt, java.util.Map<java.lang.Long,Structure> bonesPoseChannels, BlenderContext blenderContext) throws BlenderFileException
boneStructure
- the structure containing the bones' dataparent
- the parent boneresult
- the list where the newly created bone will be addedbonesPoseChannels
- a map of bones poses channelsblenderContext
- the blender context
BlenderFileException
- an exception is thrown when there is problem with the blender
filepublic java.lang.Long getBoneOMA(Bone bone)
bone
- the bone whose old memory address we seek
public java.util.Map<java.lang.Integer,java.lang.Integer> getGroupToBoneIndexMap(Structure defBaseStructure, Skeleton skeleton, BlenderContext blenderContext) throws BlenderFileException
defBaseStructure
- a bPose structure of the object
BlenderFileException
- this exception is thrown when the blender file is somehow
corruptedpublic boolean shouldBeLoaded(Structure structure, BlenderContext blenderContext)
AbstractBlenderHelper
shouldBeLoaded
in class AbstractBlenderHelper
structure
- structure to be analyzedblenderContext
- the blender context
public BoneTrack[] getTracks(Structure actionStructure, Skeleton skeleton, BlenderContext blenderContext) throws BlenderFileException
actionStructure
- the structure containing the tracksblenderContext
- the blender context
BlenderFileException
- an exception is thrown when there are problems with the blend
file
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |