The matrices are defined as:
M11, M12, M13, M14
M21, M22, M23, M24
M31, M23, M33, M34
M41, M42, M43, M44
So direction would equal Rotation.M31, Rotation.M32, Rotation.M33.
However how do I proceed from there as I would need to transform the original move vector by a matrix in order to get the transformed move vector, wouldn't I?
Also, would I have to multiply the new movement vector by the elpased game time to make sure that the camera moved smoothly no matter what, should the frame rate fluctuate?
Main Topics
Browse All Topics





by: ikeworkPosted on 2009-09-24 at 23:32:14ID: 25420424
Hi Dr_Spankenstein,
n(orientat ion);
Just take the 3rd row or column (depending on the matrix form you use) from that matrix, it is the direction vector:
Matrix Rotation = Matrix.CreateFromQuaternio
Vector direction = Rotation[3];
If you show us, how the class Matrix is defined, we can see how to access the 3rd row, "Rotation[3]" was just a guess.
ike