public class ConeJoint extends Constraint
From the Bullet manual:
To create ragdolls, the cone twist constraint is very useful for limbs like
the upper arm. It is a special point to point constraint that adds cone and
twist axis limits. The x-axis serves as twist axis.
| Modifier and Type | Field and Description |
|---|---|
static java.util.logging.Logger |
logger2
message logger for this class
|
logger15, pivotA, pivotBloggerloggerN| Constructor and Description |
|---|
ConeJoint(PhysicsRigidBody rigidBodyA,
PhysicsRigidBody rigidBodyB,
Vector3f pivotInA,
Vector3f pivotInB)
Instantiate a double-ended ConeJoint.
|
ConeJoint(PhysicsRigidBody rigidBodyA,
PhysicsRigidBody rigidBodyB,
Vector3f pivotInA,
Vector3f pivotInB,
Matrix3f rotInA,
Matrix3f rotInB)
Instantiate a double-ended ConeJoint.
|
ConeJoint(PhysicsRigidBody rigidBodyA,
Vector3f pivotInA,
Matrix3f rotInA)
Instantiate a single-ended ConeJoint with its pivot at the physics-space
origin.
|
| Modifier and Type | Method and Description |
|---|---|
Transform |
getFrameTransform(JointEnd end,
Transform storeResult)
Copy the joint's frame transform relative to the specified end.
|
float |
getSwingSpan1()
Read the span of the first swing axis.
|
float |
getSwingSpan2()
Read the span of the 2nd swing axis.
|
float |
getTwistSpan()
Read the span of the twist (local X) axis.
|
boolean |
isAngularOnly()
Test whether this joint is angular-only.
|
void |
setAngularOnly(boolean value)
Alter whether this joint is angular-only.
|
void |
setLimit(float swingSpan1,
float swingSpan2,
float twistSpan)
Alter the angular limits for this joint.
|
getAppliedImpulse, getBodyA, getBodyB, getBreakingImpulseThreshold, getConstraintType, getOverrideIterations, getPivot, getPivotA, getPivotB, isCollisionBetweenLinkedBodies, isEnabled, isFeedback, overrideIterations, setBreakingImpulseThreshold, setCollisionBetweenLinkedBodies, setEnabled, setFeedback, setPivotInA, setPivotInBcountEnds, destroy, findEnd, findOtherBody, getBody, getPhysicsSpace, setBodyA, setBodyB, setNativeId, setPhysicsSpace, toStringcompareTo, countTrackers, dumpTrackers, equals, freeUnusedObjects, hasAssignedNativeObject, hashCode, nativeId, reassignNativeId, setNativeIdNotTracked, unassignNativeObjectpublic static final java.util.logging.Logger logger2
public ConeJoint(PhysicsRigidBody rigidBodyA, Vector3f pivotInA, Matrix3f rotInA)
To be effective, the joint must be added to the PhysicsSpace of the body and the body must be dynamic.
rigidBodyA - the body to constrain (not null, alias created)pivotInA - the pivot location in A's scaled local coordinates (not
null, unaffected)rotInA - the joint orientation in A's local coordinates (rotation
matrix, unaffected)public ConeJoint(PhysicsRigidBody rigidBodyA, PhysicsRigidBody rigidBodyB, Vector3f pivotInA, Vector3f pivotInB)
To be effective, the joint must be added to the PhysicsSpace of both bodies. Also, the bodies must be distinct and at least one of them must be dynamic.
rigidBodyA - the body for the A end (not null, alias created)rigidBodyB - the body for the B end (not null, alias created)pivotInA - the pivot location in A's scaled local coordinates (not
null, unaffected)pivotInB - the pivot location in B's scaled local coordinates (not
null, unaffected)public ConeJoint(PhysicsRigidBody rigidBodyA, PhysicsRigidBody rigidBodyB, Vector3f pivotInA, Vector3f pivotInB, Matrix3f rotInA, Matrix3f rotInB)
To be effective, the joint must be added to the PhysicsSpace of both bodies. Also, the bodies must be distinct and at least one of them must be dynamic.
rigidBodyA - the body for the A end (not null, alias created)rigidBodyB - the body for the B end (not null, alias created)pivotInA - the pivot location in A's scaled local coordinates (not
null, unaffected)pivotInB - the pivot location in B's scaled local coordinates (not
null, unaffected)rotInA - the joint orientation in A's local coordinates (rotation
matrix, unaffected)rotInB - the joint orientation in B's local coordinates (rotation
matrix, unaffected)public Transform getFrameTransform(JointEnd end, Transform storeResult)
end - which end (not null)storeResult - storage for the result (modified if not null)public float getSwingSpan1()
public float getSwingSpan2()
public float getTwistSpan()
public boolean isAngularOnly()
public void setAngularOnly(boolean value)
value - the desired setting (default=false)public void setLimit(float swingSpan1,
float swingSpan2,
float twistSpan)
swingSpan1 - the desired span of the first swing axis (in radians)swingSpan2 - the desired span of the 2nd swing axis (in radians)twistSpan - the desired span of the twist (local X) axis (in
radians)