diff options
Diffstat (limited to 'src')
-rwxr-xr-x | src/demos/GLInfo.java | 2 | ||||
-rwxr-xr-x | src/demos/context/DualContext.java | 4 | ||||
-rwxr-xr-x | src/demos/es1/RedSquare.java | 2 | ||||
-rwxr-xr-x | src/demos/es2/RedSquare.java | 3 | ||||
-rwxr-xr-x | src/demos/testContextDestruction/TestContextDestruction.java | 1 |
5 files changed, 8 insertions, 4 deletions
diff --git a/src/demos/GLInfo.java b/src/demos/GLInfo.java index ba5f337..28f17be 100755 --- a/src/demos/GLInfo.java +++ b/src/demos/GLInfo.java @@ -150,7 +150,7 @@ public class GLInfo extends Thread implements GLEventListener { public static void main(String[] args) { String glprofile = null; int type = USE_NEWT ; - for(int i=args.length-1; i>=0; i--) { + for(int i=0; i<args.length; i++) { if(args[i].equals("-awt")) { type |= USE_AWT; } diff --git a/src/demos/context/DualContext.java b/src/demos/context/DualContext.java index dfb07f6..5f62d19 100755 --- a/src/demos/context/DualContext.java +++ b/src/demos/context/DualContext.java @@ -142,9 +142,11 @@ public class DualContext extends Canvas { public static void main(String[] args) { JFrame frame = new JFrame("Dual OpenGL Context Test"); + GLProfile glp = GLProfile.GetProfileDefault(); // warm up .. + AWTGraphicsScreen screen = (AWTGraphicsScreen)AWTGraphicsScreen.createDefault(); AWTGraphicsConfiguration config = (AWTGraphicsConfiguration) - GraphicsConfigurationFactory.getFactory(AWTGraphicsDevice.class).chooseGraphicsConfiguration(new GLCapabilities(null), null, screen); + GraphicsConfigurationFactory.getFactory(AWTGraphicsDevice.class).chooseGraphicsConfiguration(new GLCapabilities(glp), null, screen); final DualContext dc = new DualContext(config); frame.getContentPane().add(dc, BorderLayout.CENTER); diff --git a/src/demos/es1/RedSquare.java b/src/demos/es1/RedSquare.java index 79a3c26..7541e0f 100755 --- a/src/demos/es1/RedSquare.java +++ b/src/demos/es1/RedSquare.java @@ -225,7 +225,7 @@ public class RedSquare extends Thread implements WindowListener, KeyListener, Mo public static void main(String[] args) { String glprofile = null; int type = USE_NEWT ; - for(int i=args.length-1; i>=0; i--) { + for(int i=0; i<args.length; i++) { if(args[i].equals("-awt")) { type |= USE_AWT; } diff --git a/src/demos/es2/RedSquare.java b/src/demos/es2/RedSquare.java index cd3042c..246eced 100755 --- a/src/demos/es2/RedSquare.java +++ b/src/demos/es2/RedSquare.java @@ -88,6 +88,7 @@ public class RedSquare extends Thread implements WindowListener, MouseListener, window.setSize(width, height); // window.setFullscreen(true); window.setVisible(true); + window.enablePerfLog(true); } catch (Throwable t) { t.printStackTrace(); } @@ -269,7 +270,7 @@ public class RedSquare extends Thread implements WindowListener, MouseListener, public static void main(String[] args) { String glprofile = null; int type = USE_NEWT ; - for(int i=args.length-1; i>=0; i--) { + for(int i=0; i<args.length; i++) { if(args[i].equals("-awt")) { type |= USE_AWT; } diff --git a/src/demos/testContextDestruction/TestContextDestruction.java b/src/demos/testContextDestruction/TestContextDestruction.java index d0c3a8f..a012639 100755 --- a/src/demos/testContextDestruction/TestContextDestruction.java +++ b/src/demos/testContextDestruction/TestContextDestruction.java @@ -217,6 +217,7 @@ public class TestContextDestruction { } public void dispose(GLAutoDrawable drawable) { + System.out.println("Listener.dispose()"); } public void display(GLAutoDrawable drawable) { |