I have a RigidBody, I can rotate it by supplying a new Quaternion value, but here is the problem:
I want to rotate it SLOWLY, something like the following:
// We might need to call this method 500 times from rendering to make the RigidBody rotation is equal to FinalQuaternion
void RotateSlowly(btQuaternion FinalQuaternion)
{
btMatrix3x3 orn = body->getWorldTransform().getBasis();
// Code here to change 'orn' according to FinalQuaternion to keep rotating with certain speed until orn rotation is EQUAL to FinalQuaternion
body->getWorldTransform().setBasis(orn);
}
How can I do that?