ConeTwistConstraint SetMotorTarget

Post Reply
User avatar
Posts: 168
Joined: Tue Jan 04, 2011 11:47 pm

ConeTwistConstraint SetMotorTarget

Post by Dr.Shepherd » Mon Mar 25, 2013 10:36 pm

Code: Select all

void btConeTwistConstraint::setMotorTarget(const btQuaternion &q)
         btTransform trACur = m_rbA.getCenterOfMassTransform();
         btTransform trBCur = m_rbB.getCenterOfMassTransform();
         btQuaternion qConstraint = m_rbBFrame.getRotation().inverse() * q * m_rbAFrame.getRotation();
I don't understand how this function sets the target angle, and definitely I am missing out some fundamental mechanics knowledge here. If anyone could explain this or throw me some links would be useful.

Thanks in adance.

Post Reply