Hi Mat, OpenGL and hence the OSG uses the concept of a modelview matrix to place objects in the local coordinate into eye coordinates. The model part of this matrix places objects in the scene graph into to world coordinates and the view part places the world coordinate into eye coordinates. As OpenGL doesn't have seperate model and view matrices the OSG combines the model (scene graph) and view matrix (from the camera) to create the final modelview matrix. The osg::Camera held by the viewer is what manages the view matrix for the OSG and CameraManipulator provides this via the getInverseMatrix(). The Inverse is there as rather than placing a camera into world coordinates the view matrix does the opposite.
Robert. On 11 March 2013 16:30, Mat Mayer <[email protected]> wrote: > Hi, > > I'm new in osg and the 3D world and i try to write my own CameraManipulator. > There is just a quick question. > I figured out that the Framework is calling the getInverseMatrix method to > get the viewMatrix. Why isn't it using the the getMatrix method? Is it common > to use the inverse Matrix for the viewMatrix? Due mathematical background? > > > Thank you! > > Cheers, > Mat > > ------------------ > Read this topic online here: > http://forum.openscenegraph.org/viewtopic.php?p=53038#53038 > > > > > > _______________________________________________ > osg-users mailing list > [email protected] > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

