I created a free camera in 3DSMax that I exported using Ogremax, but have some problems computing the orientation values.
Here is the part of XML dotscene file :
Code: Select all
<node name="Camera001">
<position x="0" y="29.8503" z="-19.903" />
<scale x="1" y="1" z="1" />
<rotation qx="0.5" qy="-0.5" qz="0.5" qw="0.5" />
<camera name="Camera001" fov="0.602557">
<rotation qx="-0.707107" qy="-0" qz="-0" qw="0.707107" />
<clipping near="2.54" far="2540" />
</camera>
</node>
The position values are OK.
The camera I created for my test is simply placed : it facing UNIT_X_POSITIVE.
First, I see that I have 2 rotation property (1 for node and 1 for camera), and none have is an unit quaternion...
why ?
And secondly, the rotation values are strange.
I verified the values with the tutorial on the quaternions, and I think that there is a problem. Do you think that too ?
http://www.ogre3d.org/tikiwiki/Quaterni ... =Tutorials
Say me if I made a mistake, but :
for the first quaternion, rotation of 120 degrees ???
for the second quaternion, rotation of 90 degrees ?
The second could be correct if the UNIT direction must change (but I'm not sure with the axis).
Why the 120 on the node. It should not be oriented ?!
Someone can help me plz ?