Sunday, October 9, 2011

Rigging Update - Main Character pt 5 Arms

Just a quick update, a simple test rig for an arm.


By default, the ik handle tool doesn't allow the joints to stretch beyond their scale limit when it's being translated. The first solution we might resort to is to use setDrivenKeys to do the job manually. However, class has taught me otherwise.

This Mel script setup defies the limitations of the ik handle for the arm. It is much more effective and accurate than doing it manually due to human error.

In the script, I set up initial default values which are used to reset everything. After doing so, I defined the value of the full arm length by adding both upper and lower arm length values. Then I used a setDrivenKeyframe command which defines the:
Driver,
Driver's value,
Driven Attribute &
Driven Attribute's Value.

These will then be used in such a way where, when the Driver is at its maximum length (full arm length) without stretching, it will set the translate X value of the upper and lower arm length. That's why I need those default attributes in the previous command.

Using more similar setDrivenKeyframe command setups, the script is capable of multiplying the size of the arm length when the ik handle is being translated beyond the full length of the arm. Thus allowing infinite stretching of the arms instead of limiting them to a scale of 1.

No comments:

Post a Comment