54 ioBody1.GetMotionProperties()->AddAngularVelocityStep(
inLambda * mInvI1_A);
55 ioBody2.GetMotionProperties()->AddAngularVelocityStep(
inLambda * mInvI2_B);
91 mEffectiveMass = 0.0f;
98 return mEffectiveMass != 0.0f;
191 float mEffectiveMass = 0.0f;
192 float mTotalLambda = 0.0f;
#define JPH_NAMESPACE_END
Definition Core.h:367
#define JPH_NAMESPACE_BEGIN
Definition Core.h:361
#define JPH_ASSERT(...)
Definition IssueReporting.h:33
constexpr T Square(T inV)
Square a value.
Definition Math.h:52
AllocateFunction Allocate
Definition Memory.cpp:59
Definition GearConstraintPart.h:40
float GetTotalLambda() const
Return lagrange multiplier.
Definition GearConstraintPart.h:129
void WarmStart(Body &ioBody1, Body &ioBody2, float inWarmStartImpulseRatio)
Definition GearConstraintPart.h:105
bool SolveVelocityConstraint(Body &ioBody1, Vec3Arg inWorldSpaceHingeAxis1, Body &ioBody2, Vec3Arg inWorldSpaceHingeAxis2, float inRatio)
Definition GearConstraintPart.h:117
bool IsActive() const
Check if constraint is active.
Definition GearConstraintPart.h:96
void CalculateConstraintProperties(const Body &inBody1, Vec3Arg inWorldSpaceHingeAxis1, const Body &inBody2, Vec3Arg inWorldSpaceHingeAxis2, float inRatio)
Definition GearConstraintPart.h:69
void Deactivate()
Deactivate this constraint.
Definition GearConstraintPart.h:89
void RestoreState(StateRecorder &inStream)
Restore state of this constraint part.
Definition GearConstraintPart.h:183
bool SolvePositionConstraint(Body &ioBody1, Body &ioBody2, float inC, float inBaumgarte) const
Definition GearConstraintPart.h:139
void SaveState(StateRecorder &inStream) const
Save state of this constraint part.
Definition GearConstraintPart.h:177
Definition StateRecorder.h:48