- Sort Posts
- 4 replies
- Last post
Re: how do I get the view matrix?
April 5, 2012 - 3:36pm #4
Re: how do I get the view matrix?
April 4, 2012 - 8:16pm #3
I'm sorry, I still do not understand.I know how to obtain modelViewMatrix, but it is not I want the final data.
I want to know the coordinates of camera relative to the trackable. (When the position of the camera constant, regardless of how rotating equipment, the coordinates of this position is unchanged.)
Re: how do I get the view matrix?
April 2, 2012 - 7:57am #2
The pose returned by the trackable is the same thing as a view matrix:
QCAR::Matrix44F modelViewMatrix = QCAR::Tool::convertPose2GLMatrix(trackable->getPose());
The convertPose2GLMatrix just turns the 3x4 row-major pose matrix into a 4x4 col-major matrix.
Note this pose assumes a camera sitting at the origin, pointing in the positive Z direction with X to the right and Y down.
- Kim
Thank you very much for your answer.Your answer is very useful for me