diff --git a/include/osgProducer/Viewer b/include/osgProducer/Viewer index 540b9560d..8c4644b14 100644 --- a/include/osgProducer/Viewer +++ b/include/osgProducer/Viewer @@ -71,7 +71,7 @@ class OSGPRODUCER_EXPORT Viewer : public OsgCameraGroup, public osgGA::GUIAction void setUpViewer(unsigned int options=STANDARD_SETTINGS); /** return true if the application is done and should exit.*/ - bool done() const; + virtual bool done() const; /** Override the Producer::CameraGroup::setViewByMatrix to catch all changes to view.*/ virtual void setViewByMatrix( const Producer::Matrix & pm); diff --git a/src/osgProducer/Viewer.cpp b/src/osgProducer/Viewer.cpp index 08f0e9c6e..b38be5ea2 100644 --- a/src/osgProducer/Viewer.cpp +++ b/src/osgProducer/Viewer.cpp @@ -174,7 +174,7 @@ unsigned int Viewer::addCameraManipulator(osgGA::CameraManipulator* cm) bool Viewer::done() const { - return _done; + return _done || !validForRendering(); } void Viewer::setViewByMatrix( const Producer::Matrix & pm)