Rigging a robot limb (IK twisting trouble)

Become a member of the CGSociety

Connect, Share, and Learn with our Large Growing CG Art Community. It's Free!

Thread Tools Display Modes
  10 October 2013
Rigging a robot limb (IK twisting trouble)


So, I've got this robot limb that I need to rig. The big problem, as you can see in the picture below, is that the end of the IK chain is inside the beginning of the chain. When the leg is unfolded (to the left), it will make the IK (and consequently every joint in the chain) flip.

Doing it completely FK would work, but it doesn't provide the functionality I want, i.e. to control the entire leg with only two controllers. So, the question is, how do I work my way around this problem? Is there a way to stop my IK handles from flipping the joints, locking their X rotation (in the case of my joints, X points towards the next member in the chain) or something like that?
  10 October 2013
Just based on your picture I can't quite get how it's supposed to open. Can you provide more shots with leg opened and also other perspective too?
If it's not real-time, it's a piece of shit not a state of the art technology" - me

magic happens here... sometimes
go nodeway
  10 October 2013
Hope this expertly rushed slush animation explains it

  10 October 2013
I don't think that you can solve this with only one bone system. I don't have solution right now but I can tell you how I would start. I don't know will everything work because I'm just guessing, but it should allow you to at least start looking at the problem from different perspective.

I would start with one IK bone (red) with twist affector (i think you call it pole vector in Maya).
This bone will be placed where leg starts. Its sole purpose will be to drive leg rotation - left/right - only. Twist affector will be moved to where piston connects to armor. IK goal will be left untouched.

red = bone
blue = twist affector/pole vector

Second bone (red) will also start where leg starts and the end of it will be in first place where leg connects with armor. This will be bone with IK (we need its goal) and also it will be strechy. It will drive another two-bone system (green) with IK. It will be responsible for part of the leg without armor and piston. When its length changes it will force this part of the arm (and the green bone system) to change how wide it's opened.
The two-bone system that will be attached to this strechy bone will drive correct movement of this part of the arm. You will parent to it you geometry, to each bone different part of the arm.

red = strechy IK bone
blue = red bone IK goal
green = two-bone IK bone system, parent for each part of the arm
yellow = two-bone system IK goal

The part with the piston will be probably solved in similar manner. You will need one strechy bone that will start where first strechy bone ended (we will probably parent its root to the end of this first strechy bone) and the end of it will be where piston merges with the armor (it's the same place where we moved twist affector/pole vector of our first bone we ever placed here on the begining). Its purpose will be to simulate how far piston can open.

I don't think that you need bone system for piston itself. You will need probably just four nulls (locators in Maya?), two at each end of the piston. First pair of those nulls will be parented to IK goal of our piston strechy bone we just created and second pair will be parented to longer bone of two-bone system that we created for first strechy bone. Now, purpose one of the null from each pair will be to look at second pair. Now we should have possibility to drive both, rotation and opening of the piston with this system (each pair drives different part of the piston) and also I think we have now all that we need for armor parenting too (strechy bone will be armor parent).

Now we got our leg split on two parts + our bone for rotation left/right. We need to place some IK system (max two bones) to which we could parent our two parts and then parent this main system to our rotation bone. Twist Affector from this rotation bone will be used as main control for the leg. It will rotate our leg and open it.

I build similar system for my spider that you can see on begin.

Sorry if this doesn't solve your problem (I'm also writing most of this stuff from memory), but mechanical rigging is not as simple as placing two-three bones and have them work correctly. When I have time I may look into this later this week. Just need to build some template geometry that will look similar to yours.

PS. Just figuring out how to rig leg of this spider, so I could have only one control, took me 3 days .
If it's not real-time, it's a piece of shit not a state of the art technology" - me

magic happens here... sometimes
go nodeway

Last edited by mantragora : 10 October 2013 at 07:04 AM.
  10 October 2013
Thanks for spending the time trying to explain this, that was one titanic explanation :O

The pistons are already sorted out. All that is needed is one joint at each end, where it rotates, aim constrained towards each other, and with an up object to make sure it doesn't flip around at certain angles.

Your rig seems overly elaborate for my intended usage though... I don't know if it's possible, I don't have Maya in front o me right now, but... Don't you think that I could just put an IK on the original two joints I've got, then point/aim constrain another set of joints (the joints I will skin my geometry to) for those two joints to the IK joint chain? That way, the aim constraint should make sure that they're always facing the same way and the point constraint will keep them stuck to the ik joints positions.
  10 October 2013
Thread automatically closed

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.
CGTalk Policy/Legalities
Note that as CGTalk Members, you agree to the terms and conditions of using this website.
Thread Closed share thread

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Society of Digital Artists

Powered by vBulletin
Copyright 2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump

All times are GMT. The time now is 09:43 PM.

Powered by vBulletin
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.