[osg-users] event callback after viewer is done

Robert Osfield robert.osfield at gmail.com
Thu Oct 8 07:20:48 PDT 2015


Hi Riccardo,

On 8 October 2015 at 15:13, Riccardo Corsi <riccardo.corsi at kairos3d.it>
wrote:

> I see your point, nevertheless do you think that either:
> - having the event callback called with an "about-to-exit" event
> - having a custom callback to added and called by the viewer right before
> exiting
>
> would be a sensible addition to osg?
>

Adding a feature to the core OSG to address the needs of a single end user
that may or may not need this feature is not something I feel is
appropriate.

If there were no other way to solve the particular problem you are trying
to resolve it might be a compelling but there are number of different ways
to resolve the issue at your end:

   The exit from the application is entirely within end user control so you
can decide when it happens and what happens when you want to exit.

   The osgGA::Event/GUIEventAdapter system is extensible so end users can
subclass and dispatch their own events and have the event callbacks catch
these.

   After exiting the main frame/event loop you can call what ever you want
to call to do clean up.

These aren't the only ways either.

Robert.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/attachments/20151008/0cb57922/attachment-0003.htm>


More information about the osg-users mailing list