Quaternion Functions OK ?

Blitz3D Forums/Blitz3D Programming/Quaternion Functions OK ?


How do you know what the x, y and z components should be?



I'm using the returned quaternion values to write animation keys. When these keys are replayed then the animation has the correct amount values but on the wrong x,y,z axis. I have tested this extensively and compared the generated quaternion values using the functions in the archives with standard animation key values for identical frames and they are different.
Take an animated model -set the model to any frame using SetAnimTime()- convert the local pitch,yaw and roll values of each joint to a quaternion - the values returned are different to the animation key values for that frame - the components are mixed as explained above with the x and y component inverted - you may have to view the .b3d file as XML to view what the keys quaternion values should be.
As I said, its no big deal as I simply reallocate the value to the correct component and reverse polarity where needed.
However as you say it works for you then it could well be something else that I've overlooked.
Thanks for the reply - much appreciated !