Hi Tim,

On Sun, Sep 13, 2009 at 9:26 PM, Tim Allen <[email protected]> wrote:

> Hi,
>
> I want set my matrix to current modelview matrix and want to multiply it
> myself.Can someone please help me how  to do it in osg.
>

osg::Matrix matrix = viewer.getCamera()->getViewMatrix();
// do the stuff you want to matrix ...
viewer.getCamera()->setViewMatrix(matrix);

The OSG uses the form x' = x * M; while OpenGL now uses x' = M * x; so you
just flip the ordering.

Robert.
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to