C++学习(三一四)osg漫游器Manipulator例子
Posted hankern
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了C++学习(三一四)osg漫游器Manipulator例子相关的知识,希望对你有一定的参考价值。
osg::ref_ptr<osgGA::KeySwitchMatrixManipulator> _manipulator;
_manipulator = new osgGA::KeySwitchMatrixManipulator;
_manipulator->addMatrixManipulator( '1', "Trackball", new osgGA::TrackballManipulator() );
_manipulator->addMatrixManipulator( '2', "Flight", new osgGA::FlightManipulator() );
_manipulator->addMatrixManipulator( '3', "Drive", new osgGA::DriveManipulator() );
_manipulator->addMatrixManipulator( '4', "Terrain", new osgGA::TerrainManipulator() );
_manipulator->addMatrixManipulator( '5', "Orbit", new osgGA::OrbitManipulator() );
_manipulator->addMatrixManipulator( '6', "FirstPerson", new osgGA::FirstPersonManipulator() );
_manipulator->addMatrixManipulator( '7', "Spherical", new osgGA::SphericalManipulator() );
// _viewer->setCameraManipulator( _manipulator.get() );
_viewer->setCameraManipulator( new osgGA::TrackballManipulator() );
以上是关于C++学习(三一四)osg漫游器Manipulator例子的主要内容,如果未能解决你的问题,请参考以下文章
C++学习(三二零)osg漫游器Manipulator自带的鼠标拖拽事件Drag响应
C++学习(三二四)osg标准漫游器StandardManipulator的_ga_t1 _ga_t0