How To Use Quaternion In Blender
That should get you started.
How to use quaternion in blender. Before explaining how these rotations work we ll need to define a few terms first. I am writing a blender exporter for my scene format. I already use the info window when figuring out how to script things with blender but how would this help me extrude bones that default to something other than a quaternion rotation mode. It will show you most of the python you need to do. Test numeric values within epsilon.
My temporary solution current looks like. In blender the bones are configured to use quaternion rotation so ithought it was just a matter of finding the correct axis but it seems the values arent in the same range or i didnt find the good axis combination yet. Ok thanks for the info. Use the info window while doing what you want to do by hand. This object gives access to quaternions in blender.
I tried testing it out briefly using the xyz eulers and didn t notice any issues or problems. Numbers make up everything we do on computers including blender. Open blender delete the default cube add a monkey and switch the rotation mode to quaternion i know not much of a challenge yet for most of you but wait fill in the w x y z fields so that suzanne rotates 180 around the axis that goes through 0 0 0 and 3 4 5. 1 in computers everything is represented by numbers. Comparison operators can be done.
When rotating interactively in quaternion mode the so called norm length of the quaternion will remain constant. Math can be performed on quaternion classes. The cpp project comes from the basic tracking samples that outputs text in the console for the palm. Quaternions are 3d rotations performed by the multiplication of quaternions. The problem is in blender you cannot switch back to quaternions once you started using eulers for the animations unless you want to re do the animations.
By definition the norm of a quaternion equals 1 0 that s a normalized quaternion.