aboutsummaryrefslogtreecommitdiffstats
path: root/src/jogl/classes/com
diff options
context:
space:
mode:
Diffstat (limited to 'src/jogl/classes/com')
-rw-r--r--src/jogl/classes/com/jogamp/opengl/impl/x11/glx/X11GLXDrawableFactory.java16
-rw-r--r--src/jogl/classes/com/jogamp/opengl/impl/x11/glx/awt/X11AWTGLXGraphicsConfigurationFactory.java6
2 files changed, 5 insertions, 17 deletions
diff --git a/src/jogl/classes/com/jogamp/opengl/impl/x11/glx/X11GLXDrawableFactory.java b/src/jogl/classes/com/jogamp/opengl/impl/x11/glx/X11GLXDrawableFactory.java
index 82f57f33e..3d213c54b 100644
--- a/src/jogl/classes/com/jogamp/opengl/impl/x11/glx/X11GLXDrawableFactory.java
+++ b/src/jogl/classes/com/jogamp/opengl/impl/x11/glx/X11GLXDrawableFactory.java
@@ -236,23 +236,9 @@ public class X11GLXDrawableFactory extends GLDrawableFactoryImpl {
System.err.println("!!! Screen : "+sharedScreen);
}
- // may cause JVM SIGSEGV ?
- // X11Util.closePendingDisplayConnections();
-
sharedResourcesRunner.releaseAndWait();
- if(X11Util.getOpenDisplayConnectionNumber() > 0) {
- System.err.println("X11GLXDrawableFactory.shutdown(): Open (no close attempt) X11 Display Connection");
- X11Util.dumpOpenDisplayConnections();
- }
-
- if(X11Util.getPendingDisplayConnectionNumber()>0) {
- System.err.println("X11GLXDrawableFactory.shutdown(): Pending X11 Display Connection");
- X11Util.dumpPendingDisplayConnections();
- }
-
- // don't close pending XDisplay, since this might be a different thread as the opener
- X11Util.shutdown( false, DEBUG );
+ X11Util.shutdown( true, DEBUG );
}
protected GLDrawableImpl createOnscreenDrawableImpl(NativeSurface target) {
diff --git a/src/jogl/classes/com/jogamp/opengl/impl/x11/glx/awt/X11AWTGLXGraphicsConfigurationFactory.java b/src/jogl/classes/com/jogamp/opengl/impl/x11/glx/awt/X11AWTGLXGraphicsConfigurationFactory.java
index 225dc25a4..4b5b72cc6 100644
--- a/src/jogl/classes/com/jogamp/opengl/impl/x11/glx/awt/X11AWTGLXGraphicsConfigurationFactory.java
+++ b/src/jogl/classes/com/jogamp/opengl/impl/x11/glx/awt/X11AWTGLXGraphicsConfigurationFactory.java
@@ -83,7 +83,7 @@ public class X11AWTGLXGraphicsConfigurationFactory extends GraphicsConfiguration
long displayHandle = X11SunJDKReflection.graphicsDeviceGetDisplay(device);
if(0==displayHandle) {
- displayHandle = X11Util.createThreadLocalDisplay(null);
+ displayHandle = X11Util.createDisplay(null);
if(DEBUG) {
System.err.println("X11AWTGLXGraphicsConfigurationFactory: using a thread local X11 display");
}
@@ -91,10 +91,12 @@ public class X11AWTGLXGraphicsConfigurationFactory extends GraphicsConfiguration
if(DEBUG) {
System.err.println("X11AWTGLXGraphicsConfigurationFactory: using AWT X11 display 0x"+Long.toHexString(displayHandle));
}
+ String name = X11Util.XDisplayString(displayHandle);
+ displayHandle = X11Util.createDisplay(name);
}
((AWTGraphicsDevice)awtScreen.getDevice()).setSubType(NativeWindowFactory.TYPE_X11, displayHandle);
X11GraphicsDevice x11Device = new X11GraphicsDevice(displayHandle);
-
+ x11Device.setCloseDisplay(true);
X11GraphicsScreen x11Screen = new X11GraphicsScreen(x11Device, awtScreen.getIndex());
if(DEBUG) {
System.err.println("X11AWTGLXGraphicsConfigurationFactory: made "+x11Screen);