public class ConstraintHelper extends AbstractBlenderHelper
| Modifier and Type | Class and Description |
|---|---|
static class |
ConstraintHelper.Space
The space of target or owner transformation.
|
blenderContext, blenderVersion, fixUpAxis, upAxisRotationQuaternion| Constructor and Description |
|---|
ConstraintHelper(java.lang.String blenderVersion,
BlenderContext blenderContext)
Helper constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
applyTransform(java.lang.Long oma,
java.lang.String subtargetName,
ConstraintHelper.Space space,
Transform transform)
Applies transform to a feature (bone or spatial).
|
void |
bakeConstraints(BlenderContext blenderContext)
The method bakes all available and valid constraints.
|
Transform |
getTransform(java.lang.Long oma,
java.lang.String subtargetName,
ConstraintHelper.Space space)
The method retrieves the transform from a feature in a given space.
|
void |
loadConstraints(Structure objectStructure,
BlenderContext blenderContext)
This method reads constraints for for the given structure.
|
Matrix4f |
toMatrix(Transform transform,
Matrix4f store)
Converts given transform to the matrix.
|
applyProperties, loadLibrary, loadPropertiespublic ConstraintHelper(java.lang.String blenderVersion,
BlenderContext blenderContext)
blenderVersion - the version read from the blend fileblenderContext - the blender contextpublic void loadConstraints(Structure objectStructure, BlenderContext blenderContext) throws BlenderFileException
objectStructure - the structure we read constraint's forblenderContext - the blender contextBlenderFileExceptionpublic void bakeConstraints(BlenderContext blenderContext)
blenderContext - the blender contextpublic Transform getTransform(java.lang.Long oma, java.lang.String subtargetName, ConstraintHelper.Space space)
oma - the OMA of the feature (spatial or armature node)subtargetName - the feature's subtarget (bone in a case of armature's node)space - the space the transform is evaluated topublic void applyTransform(java.lang.Long oma,
java.lang.String subtargetName,
ConstraintHelper.Space space,
Transform transform)
oma - the OMA of the feature we apply transformation tosubtargetName - the name of the feature's subtarget (bone in case of armature)space - the space in which the given transform is to be appliedtransform - the transform we apply