Jump to content
  • Advertisement
Sign in to follow this  
akuda

Skeletal animation - keyframe matrix?

This topic is 4416 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

Hi, Recently, I'm trying to create a model format with skeletal animation, and an MS3D exporter. So the problem I find, is interpolation between keyframes - as every keyframe looks for me just like a modelview matrix element (local translation & rotation), I thought I would simply mutliply it with parent node modelview matrix, and repeat until reaching the root node (of course in father-first order). But if I would have to interpolate between to keyframes, I don't know how to do it. Would be easier to have euler rotations in keyframes, but according to some tutors mentioning about some "Gimbal's Lock", this sounds unstable. Do I have to implement (and learn first :) ) quaternions? Or is it possible to bypass it? And if it is, how to do it (tutors, links?) ?

Share this post


Link to post
Share on other sites
Advertisement
Quote:
So the problem I find, is interpolation between keyframes - as every keyframe looks for me just like a modelview matrix element (local translation & rotation), I thought I would simply mutliply it with parent node modelview matrix, and repeat until reaching the root node (of course in father-first order). But if I would have to interpolate between to keyframes, I don't know how to do it.


Interpolating involves taking two values and figuring out the 'mix' between them based on the current time and the start/end times of the two values. Research methods called linear interpolation('LERP') and spherical linear interpolation('SLERP'), for an example: http://www.euclideanspace.com/maths/algebra/realNormedAlgebra/quaternions/slerp/

Quote:
Would be easier to have euler rotations in keyframes, but according to some tutors mentioning about some "Gimbal's Lock", this sounds unstable.
Do I have to implement (and learn first :) ) quaternions? Or is it possible to bypass it?

I think the tradition for keyframe interpolation is to use quaternions which are easily converted into matrix form.

http://www.gamasutra.com/features/19980703/quaternions_01.htm
http://www.euclideanspace.com/threed/animation/keyframing/index.htm

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.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!