Sign in to follow this  

Quaternion, Matrix Animation Skinning weighted models

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

As I understand it a common approach to skinning and animated a single mesh character is to assign rotation translation (4x4) matrices to each vertex in the mesh. These matrices are refered to as joints who's sum of weights must equal 1. A vertice usually is not infulenced by more then 4 joints (or four matrices) My mesh uses Quaternions for vertex positions this mesh was a 3ds model and when parsed actually contained Quaternions for each vertex. a Quaternion has 4 floats x,y,z and w. From what I have read the w is only for Euler Angle Rotations and is a way to get around gimble lock, I have also read that gimble lock occurs when two axis are aligned. I have gathered most of this information from reading "Real-time 3d character animation", "Game Programming gems 4" , "GPU gems" by nvidia and this forum, I have been able to import a skeleton for my mesh from a bvh file. Now for my question which is two part. 1. where do the weight values go or should I say how can i ensure that each of bones weight values that a vertex uses is going to equal 1. it almost seems like a weight needs to be attached to each vertice and not the matrix(joint) but if thats the case then whats the w for in a Quaternion. Weight ? 2. I have no way to assign weights to each vertice manually (at least not at the moment ) is there a way to fudge weights? I try to take the time to read previous posts and books before i post my question but this is just one subject that I can't seem to grasp. The reason for the long explanation is really just to verify that I know what I actually think I know :) Thanks for your help Alex "The more I learn the more I realize how much I don't Know"

Share this post


Link to post
Share on other sites
The 'w' in a quaternion is one of the four elements of a quaternion: it isn't independent of the others and can't be manipulated seperately. This is similar to matrices, i.e. a rotation matrix has 9 elements and you can't just change one and expect it to stay a valid rotation matrix.

It's not clear what you're trying to do but if you are trying to blend quaternions there are two common techniques:

SLERP - look it up, it's expensive but mathematically correct
linear - simply blend them like vectors in four dimensions then renormalise

linear is good enough for most applications and is the only one I bother with.

There are some links in the FAQ and articles here on quaternions.

John

Share this post


Link to post
Share on other sites

This topic is 4815 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.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this