Hi Judy,

you do something like this:

osg::Matrixd mx = view->getCamera()->getInverseViewMatrix();
osg::Quad q = mx.getRotate();

and you can use hpr = fromQuat(q)
fromQuat can be found here

https://github.com/CCSI-CSSI/MuseOpenIG/blob/master/Core-Base/Mathematics.cpp

On Sat, Apr 1, 2017 at 10:39 AM, Judy <[email protected]> wrote:

> Hi Robert,
> As a beginner of openscenegraph,I have an urgent question that how to get
> the camera's heading pitch and yaw ?
> could you give me some suggestion about this question?
> Best regards!
> Judy Fan.
>
>
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
>


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

Reply via email to