osg wireframe mode, the mode switching point

Need to add

viewer.addEventHandler(new osgGA::StateSetManipulator(viewer.getCamera()->getOrCreateStateSet()));

Press w can switch the display mode.

In which the viewer is osg :: Viewer, different from osg :: view.

Because the display view can also add node, but can not be converted Viewer view, the message is invalid in response to the mouse and keyboard.

Guess you like

Origin www.cnblogs.com/ningmouming/p/12182606.html