diff options
author | Sven Gothel <[email protected]> | 2013-11-28 22:43:25 +0100 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2013-11-28 22:43:25 +0100 |
commit | 5906d6cd747092f1e73b32f3337563fa74cec2d2 (patch) | |
tree | 9312deae1b11d235a88af5453ac858bb82a587d1 /src/jogl/classes | |
parent | f52c89e36cccd5eb141882a4b3378efe54aa9576 (diff) |
GLDrawableFactory: destroy() -> shutdownImpl() - Add DEBUG output in implementation
Diffstat (limited to 'src/jogl/classes')
5 files changed, 19 insertions, 8 deletions
diff --git a/src/jogl/classes/javax/media/opengl/GLDrawableFactory.java b/src/jogl/classes/javax/media/opengl/GLDrawableFactory.java index 2b1d228ad..fcc1494ce 100644 --- a/src/jogl/classes/javax/media/opengl/GLDrawableFactory.java +++ b/src/jogl/classes/javax/media/opengl/GLDrawableFactory.java @@ -220,7 +220,7 @@ public abstract class GLDrawableFactory { } try { gldf.resetDisplayGamma(); - gldf.destroy(); + gldf.shutdownImpl(); } catch (Throwable t) { System.err.println("GLDrawableFactory.shutdownImpl: Catched "+t.getClass().getName()+" during factory shutdown #"+(i+1)+"/"+gldfCount+" "+gldf.getClass().getName()); if( DEBUG ) { @@ -251,7 +251,7 @@ public abstract class GLDrawableFactory { protected void enterThreadCriticalZone() {}; protected void leaveThreadCriticalZone() {}; - protected abstract void destroy(); + protected abstract void shutdownImpl(); public abstract void resetDisplayGamma(); diff --git a/src/jogl/classes/jogamp/opengl/egl/EGLDrawableFactory.java b/src/jogl/classes/jogamp/opengl/egl/EGLDrawableFactory.java index 1438107fe..f7799f1ec 100644 --- a/src/jogl/classes/jogamp/opengl/egl/EGLDrawableFactory.java +++ b/src/jogl/classes/jogamp/opengl/egl/EGLDrawableFactory.java @@ -207,17 +207,19 @@ public class EGLDrawableFactory extends GLDrawableFactoryImpl { @Override - protected final void destroy() { + protected final void shutdownImpl() { + if( DEBUG ) { + System.err.println("EGLDrawableFactory.shutdown"); + } if(null != sharedMap) { if(DEBUG) { - System.err.println("EGLDrawableFactory.destroy() .. "); dumpMap(); } Collection<SharedResource> srl = sharedMap.values(); for(Iterator<SharedResource> sri = srl.iterator(); sri.hasNext(); ) { SharedResource sr = sri.next(); if(DEBUG) { - System.err.println("EGLDrawableFactory.destroy(): "+sr.device.toString()); + System.err.println("EGLDrawableFactory.shutdown: "+sr.device.toString()); } sr.device.close(); } diff --git a/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLDrawableFactory.java b/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLDrawableFactory.java index e41c97827..9ce71cfe9 100644 --- a/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLDrawableFactory.java +++ b/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLDrawableFactory.java @@ -126,7 +126,10 @@ public class MacOSXCGLDrawableFactory extends GLDrawableFactoryImpl { } @Override - protected final void destroy() { + protected final void shutdownImpl() { + if( DEBUG ) { + System.err.println("MacOSXCGLDrawableFactory.shutdown"); + } if(null != sharedMap) { sharedMap.clear(); sharedMap = null; diff --git a/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLDrawableFactory.java b/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLDrawableFactory.java index 64ed197ea..7fa8775cf 100644 --- a/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLDrawableFactory.java +++ b/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLDrawableFactory.java @@ -140,7 +140,10 @@ public class WindowsWGLDrawableFactory extends GLDrawableFactoryImpl { @Override - protected final void destroy() { + protected final void shutdownImpl() { + if( DEBUG ) { + System.err.println("WindowsWGLDrawableFactory.shutdown"); + } if(null != sharedResourceRunner) { sharedResourceRunner.stop(); sharedResourceRunner = null; diff --git a/src/jogl/classes/jogamp/opengl/x11/glx/X11GLXDrawableFactory.java b/src/jogl/classes/jogamp/opengl/x11/glx/X11GLXDrawableFactory.java index 78e549508..f7938f463 100644 --- a/src/jogl/classes/jogamp/opengl/x11/glx/X11GLXDrawableFactory.java +++ b/src/jogl/classes/jogamp/opengl/x11/glx/X11GLXDrawableFactory.java @@ -137,7 +137,10 @@ public class X11GLXDrawableFactory extends GLDrawableFactoryImpl { } @Override - protected final void destroy() { + protected final void shutdownImpl() { + if( DEBUG ) { + System.err.println("X11GLXDrawableFactory.shutdown"); + } if(null != sharedResourceRunner) { sharedResourceRunner.stop(); sharedResourceRunner = null; |