Best way to start with Inverse Kinematic Ragdoll?

Hi! I’m creating a character pose editor, and I’d like to read some ideas on how to start developing the inverse kinematic algorithms. I’m using Unity’s ragdolls with gravity off and kinematic on. At the moment I’m testing with the Scene view. When rotation a knee, how do you make it respect the Twist and Swing limits. Are there helper functions to accomplish this, or should I make my own? And are there functions for inverse kinematic? I don’t mind looking for algorithms and translate them, but maybe there is something ready that could save me some time.

Oh, and what’s the best way to reset the character pose? Should I save the initial values of joints?

Thank you in advance!

Found this IK solver which is in the Asset Store:

Tried the test scenes but got some errors. Thinking I might play a little with it and try to tune as much as I can.

Now also found this one which is mostly code based:

http://buchhofer.com/2011/06/what-have-you-done-for-me-lately/
http://vimeo.com/24523384 (IK solver download link is in the comments)

One problem is this system was created for 2D. And I guess this is open-source, the author doesn’t mention any terms of use or license.

Well, after investigating a lot it seems I better wait for Mecanim, hopefully it will bring an IK API.

So now it’s a fact that Unity 4 Indie doesn’t support Mecanim’s IK Rigs…

I don’t want to force developers into buying Unity Pro to use the pose editor, so I kept looking a working IK Solver. Now I found the Locomotion System has two IK solvers that I can use. The IK1JointAnalytic class can solve for 3 bones, and IKSimple can solve for more than 3 bones. Both IK solvers are extended from the abstract class IKSolver, then I just had to grab these 3 classes and quickly built a test. IK1JointAnalytic seems pretty stable, not like the others I tested. IKSimple makes the bones jump a lot, but I won’t be using it at the moment.