[osg-submissions] Reuse of context IDs and cleanup of OpenGL resources.
Mathias Fröhlich
M.Froehlich at science-computing.de
Tue Apr 15 23:35:38 PDT 2008
Robert,
On Tuesday 15 April 2008 20:30, Robert Osfield wrote:
> Your test program is a pretty esoteric forcing of an error, akin to
> tricking the osgViewer into not doing the right thing. The problem is
> simply fixed by doing a releaseGLObjects() on those objects that you've
> hidden from the viewer. I'm not convinced we need a more elaborate system
> just to catch this rather unusual usage model.
We suffer from the same problem here.
While we might be able to work around the problem more easily than Mark, it
would also be better to have the opengl objects destroyed when a
GraphicsContext gets destroyed.
The caching of the extensions dependent in the context id's that over time get
different Graphics contexts has also prooven to be a problem in our
application. The Problem is tiggered by a strange side effect of the current
nvidia driver, but it happens and breaks our application. (Allocate a XPixmap
Graphics context makes the /dev/nvidiactl file permissions unreadable for a
user which in turn disables direct rendering. And this driver verison offers
frame buffer objects only in direct rendering mode. But the fbo supported
flag for a context with is still enabled even if no longer applicable...)
Wouldn't it be better to stick such objects and cached information into the
GraphicsContext class? Then they get deleted, once they are no longer
valid ...
Greetings
Mathias
--
Dr. Mathias Fröhlich, science + computing ag, Software Solutions
Hagellocher Weg 71-75, D-72070 Tuebingen, Germany
Phone: +49 7071 9457-268, Fax: +49 7071 9457-511
--
Vorstand/Board of Management:
Dr. Bernd Finkbeiner, Dr. Florian Geyer,
Dr. Roland Niemeier, Dr. Arno Steitz, Dr. Ingrid Zech
Vorsitzender des Aufsichtsrats/
Chairman of the Supervisory Board:
Prof. Dr. Hanns Ruder
Sitz/Registered Office: Tuebingen
Registergericht/Registration Court: Stuttgart
Registernummer/Commercial Register No.: HRB 382196
More information about the osg-submissions
mailing list