java.lang.Object
com.github.stephengold.joltjni.JoltPhysicsObject
com.github.stephengold.joltjni.JointState
- All Implemented Interfaces:
ConstJointState,ConstJoltPhysicsObject,AutoCloseable,Comparable<JoltPhysicsObject>
The local-space coordinate transform of an animation joint relative to its
parent joint. (native type:
SkeletonPose::JointState)-
Method Summary
Modifier and TypeMethodDescriptionCopy the rotation.voidgetRotation(Quat storeResult) Copy the rotation.Copy the translation offset.voidgetTranslation(Vec3 storeResult) Copy the translation offset.voidset(ConstJointState source) Copy both components from the argument.voidsetRotation(float qx, float qy, float qz, float qw) Alter the rotation component.voidsetRotation(QuatArg rotation) Alter the rotation component.voidsetTranslation(float x, float y, float z) Alter the translation offset component.voidsetTranslation(Vec3Arg offset) Alter the translation offset component.Methods inherited from class com.github.stephengold.joltjni.JoltPhysicsObject
close, compareTo, equals, getContainingObject, hasAssignedNativeObject, hashCode, isCleanerStarted, ownsNativeObject, setVirtualAddress, setVirtualAddress, startCleaner, targetVa, targetVaOrZero, toString, vaMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.lang.Comparable
compareToMethods inherited from interface com.github.stephengold.joltjni.readonly.ConstJoltPhysicsObject
close, hasAssignedNativeObject, ownsNativeObject, targetVa, targetVaOrZero
-
Method Details
-
set
Copy both components from the argument.- Parameters:
source- the state to copy (notnull, unaffected)
-
setRotation
public void setRotation(float qx, float qy, float qz, float qw) Alter the rotation component. (native attribute: mRotation)- Parameters:
qx- the X component of the desired rotation (default=0)qy- the Y component of the desired rotation (default=0)qz- the Z component of the desired rotation (default=0)qw- the W component of the desired rotation (default=1)
-
setRotation
Alter the rotation component. (native attribute: mRotation)- Parameters:
rotation- the desired rotation (notnull, unaffected, default=(0,0,0,1))
-
setTranslation
public void setTranslation(float x, float y, float z) Alter the translation offset component. (native attribute: mTranslation)- Parameters:
x- the desired X offset (default=0)y- the desired Y offset (default=0)z- the desired Z offset (default=0)
-
setTranslation
Alter the translation offset component. (native attribute: mTranslation)- Parameters:
offset- the desired offset (notnull, unaffected, default=(0,0,0))
-
getRotation
Copy the rotation. The state is unaffected. (native attribute: mRotation)- Specified by:
getRotationin interfaceConstJointState- Returns:
- a new rotation quaternion
-
getRotation
Copy the rotation. The state is unaffected. (native attribute: mRotation)- Specified by:
getRotationin interfaceConstJointState- Parameters:
storeResult- storage for the rotation (notnull, modified)
-
getTranslation
Copy the translation offset. The state is unaffected. (native attribute: mTranslation)- Specified by:
getTranslationin interfaceConstJointState- Returns:
- a new offset vector
-
getTranslation
Copy the translation offset. The state is unaffected. (native attribute: mTranslation)- Specified by:
getTranslationin interfaceConstJointState- Parameters:
storeResult- storage for the offset (notnull, modified)
-