Fixed panning bug, when using RUN_ON_DEMAND, that resulted in the camera being thrown off towards infinity.
The solution for to refactor the way that events are checked so I add a bool return type to checkEvents() method across osgViewer::GraphcisWindow, osgGA::Devive and osgViewer::Viewer/CompositeViewer classes
This commit is contained in:
@@ -53,7 +53,8 @@ class OSGVIEWER_EXPORT GraphicsWindow : public osg::GraphicsContext, public osgG
|
||||
osgGA::EventQueue* getEventQueue() { return _eventQueue.get(); }
|
||||
const osgGA::EventQueue* getEventQueue() const { return _eventQueue.get(); }
|
||||
|
||||
virtual void checkEvents() {}
|
||||
/** Check events, return true if events have been received.*/
|
||||
virtual bool checkEvents() { return false; }
|
||||
|
||||
/** Set the window's position and size.*/
|
||||
void setWindowRectangle(int x, int y, int width, int height)
|
||||
|
||||
Reference in New Issue
Block a user