PDA

View Full Version : Scaling legs


doffer
10-29-2011, 06:55 PM
Hi guys.

I have a feature I'd like on my rig. Mainly the legs, but could perhaps be useful on arms as well. I can't quite wrap my head around the thinking behind it, and thought perhaps you guys could help out.

Lets imagine a very standard leg setup.
I have IK chain, FK chain and BIND chain.
Some kind of blend, probably blend colors.

Then I have stretch, the usual IK stretch with distance nodes, checking the leg length against the length between hip and ik solver/controler and whatever number that is, above one, is plugged into the scale of the leg, down the length.

One feature I'd like now, is to be able to scale the leg, by dialing a "Upper leg scale" and "Lower leg scale" on the foot ctrl. This makes the ankle and hip stay in place but pushes out the knee to accomodate the new length.
The usefulness lies primarily in fixing small spacing issues with the knee, which can otherwise be almost impossible to do, such as popping knees in a walk.

How would you go about doing this, since the scale channel already is used to scale for stretch.
Does this at all make sense?

Any ideas. It could be general or specific. I just need a kick start to go off from, as I don't know how to go about it.

Horganovski
10-29-2011, 09:24 PM
Just because the stretch is driving the scale doesn't mean you can't wire in a squash attribute too and have it affect the scale as well. I just do it by having a multiply node (defaulting to one) between the output of the nodes calculating the stretch and the scale input of the joint. Then just drive the multiply value from a custom attribute on the leg controller.

Cheers,
Brian

doffer
10-29-2011, 09:56 PM
Brilliant! It's implemented and works perfectly!
Thanks a lot :)

Horganovski
10-29-2011, 11:00 PM
You're welcome, glad that helped.

Cheers,
Brian

CGTalk Moderation
10-29-2011, 11:00 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.