summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2012-07-25 04:29:47 +0200
committerSven Gothel <[email protected]>2012-07-25 04:29:47 +0200
commit9c637746e8061781d6002bb279193619857cda85 (patch)
treed5e4dc26a06f9b89c24d074afae79ff8294ab7c9 /src
parentd1a1ad3599c3760d4e7ceecf35d15de485c8b652 (diff)
Adapt to JOGL changes commit 00bef95008b02cc71e166da122884402e9381f44
Diffstat (limited to 'src')
-rwxr-xr-xsrc/demos/context/DualContext.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/demos/context/DualContext.java b/src/demos/context/DualContext.java
index 05f01c8..5df79fd 100755
--- a/src/demos/context/DualContext.java
+++ b/src/demos/context/DualContext.java
@@ -49,6 +49,7 @@ import java.awt.event.ActionListener;
import javax.media.nativewindow.GraphicsConfigurationFactory;
import javax.media.nativewindow.NativeWindow;
import javax.media.nativewindow.NativeWindowFactory;
+import javax.media.nativewindow.VisualIDHolder;
import javax.media.opengl.GL;
import javax.media.opengl.GL2;
import javax.media.opengl.GL2ES1;
@@ -85,7 +86,8 @@ public class DualContext extends Canvas {
public DualContext(AWTGraphicsConfiguration config) {
super(unwrap(config));
- NativeWindow win = NativeWindowFactory.getFactory(getClass()).getNativeWindow(this, config);
+ NativeWindowFactory.getFactory(getClass());
+ NativeWindow win = NativeWindowFactory.getNativeWindow(this, config);
GLCapabilities glCaps = (GLCapabilities) win.getGraphicsConfiguration().getNativeGraphicsConfiguration().getChosenCapabilities();
drawable = GLDrawableFactory.getFactory(glCaps.getGLProfile()).createGLDrawable(win);
context1 = drawable.createContext(null);
@@ -159,7 +161,7 @@ public class DualContext extends Canvas {
AWTGraphicsScreen screen = (AWTGraphicsScreen)AWTGraphicsScreen.createDefault();
GLCapabilities caps = new GLCapabilities(glp);
AWTGraphicsConfiguration config = (AWTGraphicsConfiguration)
- GraphicsConfigurationFactory.getFactory(AWTGraphicsDevice.class).chooseGraphicsConfiguration(caps, caps, null, screen);
+ GraphicsConfigurationFactory.getFactory(AWTGraphicsDevice.class, caps.getClass()).chooseGraphicsConfiguration(caps, caps, null, screen, VisualIDHolder.VID_UNDEFINED);
final DualContext dc = new DualContext(config);
frame.getContentPane().add(dc, BorderLayout.CENTER);