Interface ConstConstraint
- All Superinterfaces:
Comparable<JoltPhysicsObject>
,ConstJoltPhysicsObject
- All Known Subinterfaces:
ConstTwoBodyConstraint
- All Known Implementing Classes:
ConeConstraint
,Constraint
,ConstraintRef
,DistanceConstraint
,FixedConstraint
,GearConstraint
,HingeConstraint
,PathConstraint
,PointConstraint
,PulleyConstraint
,RackAndPinionConstraint
,SixDofConstraint
,SliderConstraint
,SwingTwistConstraint
,TwoBodyConstraint
,TwoBodyConstraintRef
,VehicleConstraint
Read-only access to a
Constraint
. (native type: const Constraint)-
Method Summary
Modifier and TypeMethodDescriptionint
Return the constraint's priority when solving.Convert the constraint to aConstraintSettings
object.boolean
Test whether the constraint is enabled.int
Return the override for the number of position iterations used in the solver.int
Return the override for the number of velocity iterations used in the solver.Return the constraint's subtype.getType()
Return the constraint's type.Methods inherited from interface java.lang.Comparable
compareTo
Methods inherited from interface com.github.stephengold.joltjni.readonly.ConstJoltPhysicsObject
close, hasAssignedNativeObject, ownsNativeObject, targetVa
-
Method Details
-
getConstraintPriority
int getConstraintPriority()Return the constraint's priority when solving. The constraint is unaffected.- Returns:
- the priority level
-
getConstraintSettings
ConstraintSettingsRef getConstraintSettings()Convert the constraint to aConstraintSettings
object. The constraint is unaffected.- Returns:
- a new reference to a new settings object
-
getEnabled
boolean getEnabled()Test whether the constraint is enabled. The constraint is unaffected.- Returns:
true
if enabled, otherwisefalse
-
getNumPositionStepsOverride
int getNumPositionStepsOverride()Return the override for the number of position iterations used in the solver. The constraint is unaffected.- Returns:
- the number of iterations, or 0 to use the default in
PhysicsSettings
-
getNumVelocityStepsOverride
int getNumVelocityStepsOverride()Return the override for the number of velocity iterations used in the solver. The constraint is unaffected.- Returns:
- the number of iterations, or 0 to use the default in
PhysicsSettings
-
getSubType
EConstraintSubType getSubType()Return the constraint's subtype. The constraint is unaffected.- Returns:
- an enum value (not null)
-
getType
EConstraintType getType()Return the constraint's type. The constraint is unaffected.- Returns:
- an enum value (not null)
-