private void UpdateRotationEulerExplicit(float dt) { rotation += .5f * angularVelocity * rotation * dt; rotation.Normalize(); angularVelocity += angularAcceleration * dt; }
private void UpdateRotationKinematic(float dt) { //rotation += .5f * velQuat * rotation * dt + (accQuat * rotation + .5f * velQuat * velQuat * rotation) * dt * dt; rotation += angularVelocity * rotation * dt * .5f + angularAcceleration * rotation * dt * dt * .25f - rotation * angularVelocity.sqrMagnitude * dt * dt * .125f; rotation.Normalize(); angularVelocity += angularAcceleration * dt; }