Jump to content
  • Advertisement
Sign in to follow this  
lauris71

IK - Euler angles or quaternions?

This topic is 2646 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I have got skeletal animation working as they should and now planning to enhance these with limb IK solvers (to keep feet on ground etc.)

Quaternions are much nicer for keyframed animations, no question.
But for IK solver Euler angles seem to be much more natural:

  • They allow me specify constraints easily (as maximum/minimum rotation angles). Converting constraints to quaternion space seems quite clumsy...
  • Joints with only 1 DOF (knees, elbows) have only 1 adjustable component in Euler angle based rotation, but 3(4) in quaternion, meaning that solver will probably be slower and noisier.
    Am I overlooking something? How are IK solvers and constraints normally added to keyframed animation systems?
    Or is it pseudoproblem, as (hopefully) most IK adjustments to legs and hands are small enough, so the lack of constraints would not be visible?

    Any help would be welcome!

Share this post


Link to post
Share on other sites
Advertisement

But for IK solver Euler angles seem to be much more natural:

Entirely incorrect. Rotations with quats are more natural than Eulers. Since IK deals with rotations, it also sees benefits for having a more natural representation.

[color=#1C2837][size=2]Converting constraints to quaternion space seems quite clumsy...[/quote]
[color=#1C2837][size=2]Not if the constraints are already in quaternion space.

Share this post


Link to post
Share on other sites

[color="#1C2837"]Converting constraints to quaternion space seems quite clumsy...

[color="#1C2837"]Not if the constraints are already in quaternion space.
[/quote]
But how do you specify constraints in quaternion space?
It can imagine that it is simple for 1 DOF joints - just restricting quaternion to single XYZ component and giving maximum and minimum values for it. It translates directly to maximum and minimum angles of rotations in given direction.
But 2 or 3 DOF joints? Should simply restricting XYZ components work here too? And does these values have some simple geometric meaning so one can specify them manually during skeleton creation?

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!