From e8ec19edb5332d5246901966b45082e4c6790901 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Thu, 1 Sep 2011 02:48:27 +0200 Subject: Tests: Exchange GL2, ES1 GLEventListener to ES2 - mobile test preparation. --- .../opengl/test/junit/jogl/awt/TestAWT01GLn.java | 4 +- .../jogl/awt/TestAWT03GLCanvasRecreate01.java | 5 +- .../test/junit/jogl/awt/TestSwingAWT01GLn.java | 8 +-- ...TestSwingAWTRobotUsageBeforeJOGLInitBug411.java | 10 ++-- .../offscreen/TestOffscreen01GLPBufferNEWT.java | 17 +++---- .../jogl/offscreen/TestOffscreen02BitmapNEWT.java | 12 ++--- .../junit/newt/TestDisplayLifecycle01NEWT.java | 15 ++---- .../junit/newt/TestDisplayLifecycle02NEWT.java | 15 ++---- .../test/junit/newt/TestEventSourceNotAWTBug.java | 8 +-- .../test/junit/newt/TestFocus01SwingAWTRobot.java | 5 +- .../test/junit/newt/TestFocus02SwingAWTRobot.java | 4 +- .../test/junit/newt/TestGLWindows00NEWT.java | 4 +- .../test/junit/newt/TestGLWindows01NEWT.java | 4 +- .../test/junit/newt/TestListenerCom01AWT.java | 18 +------ .../test/junit/newt/TestRemoteGLWindows01NEWT.java | 6 +-- .../junit/newt/TestWindowClosingProtocol01AWT.java | 7 +-- .../newt/TestWindowClosingProtocol02NEWT.java | 5 +- .../newt/TestWindowClosingProtocol03NewtAWT.java | 5 +- .../junit/newt/parenting/TestParenting01NEWT.java | 16 +++--- .../junit/newt/parenting/TestParenting01aAWT.java | 58 +++------------------- .../junit/newt/parenting/TestParenting01bAWT.java | 21 +------- .../junit/newt/parenting/TestParenting01cAWT.java | 28 ++--------- .../newt/parenting/TestParenting01cSwingAWT.java | 7 ++- .../junit/newt/parenting/TestParenting02NEWT.java | 17 ++----- .../junit/newt/parenting/TestParenting03AWT.java | 4 +- .../junit/newt/parenting/TestParenting03bAWT.java | 6 +-- 26 files changed, 86 insertions(+), 223 deletions(-) (limited to 'src/test/com/jogamp') diff --git a/src/test/com/jogamp/opengl/test/junit/jogl/awt/TestAWT01GLn.java b/src/test/com/jogamp/opengl/test/junit/jogl/awt/TestAWT01GLn.java index 97c41ba31..55bdb9514 100644 --- a/src/test/com/jogamp/opengl/test/junit/jogl/awt/TestAWT01GLn.java +++ b/src/test/com/jogamp/opengl/test/junit/jogl/awt/TestAWT01GLn.java @@ -34,7 +34,7 @@ import javax.media.opengl.awt.GLCanvas; import com.jogamp.opengl.util.Animator; import com.jogamp.opengl.test.junit.util.UITestCase; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; import java.awt.Frame; @@ -83,7 +83,7 @@ public class TestAWT01GLn extends UITestCase { protected void runTestGL(GLCapabilities caps) throws InterruptedException { glCanvas = new GLCanvas(caps); Assert.assertNotNull(glCanvas); - glCanvas.addGLEventListener(new Gears()); + glCanvas.addGLEventListener(new GearsES2()); frame.add(glCanvas); // Revalidate size/layout. diff --git a/src/test/com/jogamp/opengl/test/junit/jogl/awt/TestAWT03GLCanvasRecreate01.java b/src/test/com/jogamp/opengl/test/junit/jogl/awt/TestAWT03GLCanvasRecreate01.java index 4dabb67e4..aa7b4e06b 100644 --- a/src/test/com/jogamp/opengl/test/junit/jogl/awt/TestAWT03GLCanvasRecreate01.java +++ b/src/test/com/jogamp/opengl/test/junit/jogl/awt/TestAWT03GLCanvasRecreate01.java @@ -33,7 +33,8 @@ import javax.media.opengl.awt.GLCanvas; import com.jogamp.opengl.util.Animator; import com.jogamp.opengl.test.junit.util.UITestCase; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; + import com.jogamp.opengl.test.junit.util.MiscUtils; import java.awt.Frame; @@ -65,7 +66,7 @@ public class TestAWT03GLCanvasRecreate01 extends UITestCase { public void init() { glCanvas = new GLCanvas(); Assert.assertNotNull(glCanvas); - glCanvas.addGLEventListener(new Gears()); + glCanvas.addGLEventListener(new GearsES2()); animator = new Animator(glCanvas); animator.start(); diff --git a/src/test/com/jogamp/opengl/test/junit/jogl/awt/TestSwingAWT01GLn.java b/src/test/com/jogamp/opengl/test/junit/jogl/awt/TestSwingAWT01GLn.java index b6192b28a..29f83fcdf 100644 --- a/src/test/com/jogamp/opengl/test/junit/jogl/awt/TestSwingAWT01GLn.java +++ b/src/test/com/jogamp/opengl/test/junit/jogl/awt/TestSwingAWT01GLn.java @@ -35,7 +35,8 @@ import javax.media.opengl.awt.GLCanvas; import com.jogamp.opengl.util.Animator; import com.jogamp.opengl.test.junit.util.UITestCase; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; + import java.awt.Frame; import java.awt.Window; @@ -46,12 +47,11 @@ import org.junit.BeforeClass; import org.junit.Test; import static org.junit.Assume.*; -import static org.junit.Assert.*; import static javax.swing.SwingUtilities.*; /** * Tests context creation + display on various kinds of Window implementations. - * @author Michael Bien + * @author Michael Bien, et. al. */ public class TestSwingAWT01GLn extends UITestCase { private Window[] windows; @@ -83,7 +83,7 @@ public class TestSwingAWT01GLn extends UITestCase { Runnable test = new Runnable() { public void run() { glCanvas[0] = new GLCanvas(caps); - glCanvas[0].addGLEventListener(new Gears()); + glCanvas[0].addGLEventListener(new GearsES2()); window.add(glCanvas[0]); // Revalidate size/layout. diff --git a/src/test/com/jogamp/opengl/test/junit/jogl/newt/TestSwingAWTRobotUsageBeforeJOGLInitBug411.java b/src/test/com/jogamp/opengl/test/junit/jogl/newt/TestSwingAWTRobotUsageBeforeJOGLInitBug411.java index 64c1f15ce..fb92e92ac 100644 --- a/src/test/com/jogamp/opengl/test/junit/jogl/newt/TestSwingAWTRobotUsageBeforeJOGLInitBug411.java +++ b/src/test/com/jogamp/opengl/test/junit/jogl/newt/TestSwingAWTRobotUsageBeforeJOGLInitBug411.java @@ -28,7 +28,8 @@ package com.jogamp.opengl.test.junit.jogl.newt; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; + import com.jogamp.opengl.test.junit.util.*; import java.lang.reflect.InvocationTargetException; @@ -110,8 +111,6 @@ public class TestSwingAWTRobotUsageBeforeJOGLInitBug411 extends UITestCase { @BeforeClass public static void setup() throws InterruptedException, InvocationTargetException, AWTException { - int count; - System.err.println("TestSwingAWTRobotUsageBeforeJOGLInitBug411.setup(): Start Pre-JOGL-Swing"); // GLProfile.initSingleton(false); @@ -203,7 +202,7 @@ public class TestSwingAWTRobotUsageBeforeJOGLInitBug411 extends UITestCase { AWTRobotUtil.toFront(robot, frame); - drawable.addGLEventListener(new Gears()); + drawable.addGLEventListener(new GearsES2()); for(int i=0; i<100; i++) { javax.swing.SwingUtilities.invokeAndWait(new Runnable() { @@ -220,7 +219,6 @@ public class TestSwingAWTRobotUsageBeforeJOGLInitBug411 extends UITestCase { drawable.addGLEventListener(new SwingGLAction()); Point p0 = canvas.getLocationOnScreen(); - Rectangle r0 = canvas.getBounds(); robot.mouseMove( (int) ( p0.getX() + .5 ) , (int) ( p0.getY() + .5 ) ); robot.mousePress(InputEvent.BUTTON1_MASK); @@ -257,7 +255,7 @@ public class TestSwingAWTRobotUsageBeforeJOGLInitBug411 extends UITestCase { win0.setVisible(true); Screen screen = win0.getScreen(); win0.setPosition(screen.getWidth()-150, 0); - win0.addGLEventListener(new Gears()); + win0.addGLEventListener(new GearsES2()); Animator anim = new Animator(win0); anim.start(); diff --git a/src/test/com/jogamp/opengl/test/junit/jogl/offscreen/TestOffscreen01GLPBufferNEWT.java b/src/test/com/jogamp/opengl/test/junit/jogl/offscreen/TestOffscreen01GLPBufferNEWT.java index 8b4d199e8..561819485 100644 --- a/src/test/com/jogamp/opengl/test/junit/jogl/offscreen/TestOffscreen01GLPBufferNEWT.java +++ b/src/test/com/jogamp/opengl/test/junit/jogl/offscreen/TestOffscreen01GLPBufferNEWT.java @@ -28,7 +28,6 @@ package com.jogamp.opengl.test.junit.jogl.offscreen; - import com.jogamp.newt.Display; import com.jogamp.newt.NewtFactory; import com.jogamp.newt.Screen; @@ -46,7 +45,7 @@ import javax.media.opengl.*; import javax.media.nativewindow.*; import com.jogamp.opengl.test.junit.util.UITestCase; -import com.jogamp.opengl.test.junit.jogl.demos.es1.RedSquareES1; +import com.jogamp.opengl.test.junit.jogl.demos.es2.RedSquareES2; import java.io.IOException; public class TestOffscreen01GLPBufferNEWT extends UITestCase { @@ -88,7 +87,7 @@ public class TestOffscreen01GLPBufferNEWT extends UITestCase { Assert.assertNotNull(glWindow); glWindow.setVisible(true); - GLEventListener demo = new RedSquareES1(); + GLEventListener demo = new RedSquareES2(); WindowUtilNEWT.setDemoFields(demo, window, glWindow, false); glWindow.addGLEventListener(demo); @@ -182,7 +181,7 @@ public class TestOffscreen01GLPBufferNEWT extends UITestCase { Assert.assertNotNull(glWindows[i]); glWindows[i].setVisible(true); - demos[i] = new RedSquareES1(); + demos[i] = new RedSquareES2(); WindowUtilNEWT.setDemoFields(demos[i], windows[i], glWindows[i], false); glWindows[i].addGLEventListener(demos[i]); } @@ -235,7 +234,7 @@ public class TestOffscreen01GLPBufferNEWT extends UITestCase { glWindows[i] = GLWindow.create(windows[i]); Assert.assertNotNull(glWindows[i]); glWindows[i].setVisible(true); - demos[i] = new RedSquareES1(); + demos[i] = new RedSquareES2(); WindowUtilNEWT.setDemoFields(demos[i], windows[i], glWindows[i], false); glWindows[i].addGLEventListener(demos[i]); } @@ -282,19 +281,15 @@ public class TestOffscreen01GLPBufferNEWT extends UITestCase { Assert.assertNotNull(glWindow); glWindow.setVisible(true); - GLWindow windowOnScreen = null; WindowListener wl=null; MouseListener ml=null; SurfaceUpdatedListener ul=null; - GLEventListener demo = new RedSquareES1(); + GLEventListener demo = new RedSquareES2(); Assert.assertNotNull(demo); - WindowUtilNEWT.run(glWindow, demo, windowOnScreen, wl, ml, ul, 2, true /*snapshot*/, false /*debug*/); + WindowUtilNEWT.run(glWindow, demo, null, wl, ml, ul, 2, true /*snapshot*/, false /*debug*/); - if(null!=windowOnScreen) { - windowOnScreen.destroy(); - } if(null!=glWindow) { glWindow.destroy(); } diff --git a/src/test/com/jogamp/opengl/test/junit/jogl/offscreen/TestOffscreen02BitmapNEWT.java b/src/test/com/jogamp/opengl/test/junit/jogl/offscreen/TestOffscreen02BitmapNEWT.java index 766f64d70..55675f2fc 100644 --- a/src/test/com/jogamp/opengl/test/junit/jogl/offscreen/TestOffscreen02BitmapNEWT.java +++ b/src/test/com/jogamp/opengl/test/junit/jogl/offscreen/TestOffscreen02BitmapNEWT.java @@ -46,7 +46,7 @@ import javax.media.opengl.*; import javax.media.nativewindow.*; import com.jogamp.opengl.test.junit.util.UITestCase; -import com.jogamp.opengl.test.junit.jogl.demos.es1.RedSquareES1; +import com.jogamp.opengl.test.junit.jogl.demos.es2.RedSquareES2; import java.io.IOException; public class TestOffscreen02BitmapNEWT extends UITestCase { @@ -97,7 +97,7 @@ public class TestOffscreen02BitmapNEWT extends UITestCase { Assert.assertNotNull(glWindow); glWindow.setVisible(true); - GLEventListener demo = new RedSquareES1(); + GLEventListener demo = new RedSquareES2(); WindowUtilNEWT.setDemoFields(demo, window, glWindow, false); glWindow.addGLEventListener(demo); @@ -140,19 +140,15 @@ public class TestOffscreen02BitmapNEWT extends UITestCase { Assert.assertNotNull(glWindow); glWindow.setVisible(true); - GLWindow windowOnScreen = null; WindowListener wl=null; MouseListener ml=null; SurfaceUpdatedListener ul=null; - GLEventListener demo = new RedSquareES1(); + GLEventListener demo = new RedSquareES2(); Assert.assertNotNull(demo); - WindowUtilNEWT.run(glWindow, demo, windowOnScreen, wl, ml, ul, 2, true /*snapshot*/, false /*debug*/); + WindowUtilNEWT.run(glWindow, demo, null, wl, ml, ul, 2, true /*snapshot*/, false /*debug*/); - if(null!=windowOnScreen) { - windowOnScreen.destroy(); - } if(null!=glWindow) { glWindow.destroy(); } diff --git a/src/test/com/jogamp/opengl/test/junit/newt/TestDisplayLifecycle01NEWT.java b/src/test/com/jogamp/opengl/test/junit/newt/TestDisplayLifecycle01NEWT.java index 0fa2fcff0..d027460db 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/TestDisplayLifecycle01NEWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/TestDisplayLifecycle01NEWT.java @@ -28,19 +28,10 @@ package com.jogamp.opengl.test.junit.newt; -import java.lang.reflect.*; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - import org.junit.Assert; -import org.junit.Before; import org.junit.BeforeClass; -import org.junit.After; -import org.junit.AfterClass; import org.junit.Test; -import javax.media.nativewindow.*; import javax.media.opengl.*; import com.jogamp.newt.*; @@ -50,7 +41,7 @@ import java.io.IOException; import com.jogamp.opengl.test.junit.util.UITestCase; import com.jogamp.opengl.test.junit.util.MiscUtils; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; public class TestDisplayLifecycle01NEWT extends UITestCase { static GLProfile glp; @@ -85,7 +76,7 @@ public class TestDisplayLifecycle01NEWT extends UITestCase { } glWindow.setUpdateFPSFrames(1, null); - GLEventListener demo = new Gears(); + GLEventListener demo = new GearsES2(); setDemoFields(demo, glWindow); glWindow.addGLEventListener(demo); glWindow.addWindowListener(new TraceWindowAdapter()); @@ -203,7 +194,7 @@ public class TestDisplayLifecycle01NEWT extends UITestCase { // destruction .. window.destroy(); - display.dumpDisplayList("Post destroy(true)"); + Display.dumpDisplayList("Post destroy(true)"); // end-state == start-state Assert.assertEquals(0,Display.getActiveDisplayNumber()); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/TestDisplayLifecycle02NEWT.java b/src/test/com/jogamp/opengl/test/junit/newt/TestDisplayLifecycle02NEWT.java index 722934519..4b3c5d506 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/TestDisplayLifecycle02NEWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/TestDisplayLifecycle02NEWT.java @@ -28,19 +28,10 @@ package com.jogamp.opengl.test.junit.newt; -import java.lang.reflect.*; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - import org.junit.Assert; -import org.junit.Before; import org.junit.BeforeClass; -import org.junit.After; -import org.junit.AfterClass; import org.junit.Test; -import javax.media.nativewindow.*; import javax.media.opengl.*; import com.jogamp.newt.*; @@ -50,7 +41,7 @@ import java.io.IOException; import com.jogamp.opengl.test.junit.util.UITestCase; import com.jogamp.opengl.test.junit.util.MiscUtils; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; public class TestDisplayLifecycle02NEWT extends UITestCase { static GLProfile glp; @@ -78,7 +69,7 @@ public class TestDisplayLifecycle02NEWT extends UITestCase { GLWindow glWindow = GLWindow.create(caps); glWindow.setUpdateFPSFrames(1, null); - GLEventListener demo = new Gears(); + GLEventListener demo = new GearsES2(); setDemoFields(demo, glWindow); glWindow.addGLEventListener(demo); glWindow.addWindowListener(new TraceWindowAdapter()); @@ -200,7 +191,7 @@ public class TestDisplayLifecycle02NEWT extends UITestCase { Assert.assertEquals(false,window.isNativeValid()); Assert.assertEquals(false,window.isVisible()); - display.dumpDisplayList("Post destroy(true)"); + Display.dumpDisplayList("Post destroy(true)"); // end-state == start-state Assert.assertEquals(0,Display.getActiveDisplayNumber()); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/TestEventSourceNotAWTBug.java b/src/test/com/jogamp/opengl/test/junit/newt/TestEventSourceNotAWTBug.java index ba8c2f731..e6f3f0ac9 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/TestEventSourceNotAWTBug.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/TestEventSourceNotAWTBug.java @@ -28,11 +28,7 @@ package com.jogamp.opengl.test.junit.newt; -import org.junit.Assert; -import org.junit.Before; import org.junit.BeforeClass; -import org.junit.After; -import org.junit.AfterClass; import org.junit.Test; import java.io.IOException; @@ -45,7 +41,7 @@ import javax.swing.WindowConstants; import com.jogamp.newt.awt.NewtCanvasAWT; import com.jogamp.newt.opengl.GLWindow; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; import com.jogamp.opengl.test.junit.util.*; /** @@ -69,7 +65,7 @@ public class TestEventSourceNotAWTBug extends UITestCase { jf.getContentPane().add(canvas); // The following line isn't event necessary to see the problem. - glWindow.addGLEventListener(new Gears()); + glWindow.addGLEventListener(new GearsES2()); final JFrame f_jf = jf; diff --git a/src/test/com/jogamp/opengl/test/junit/newt/TestFocus01SwingAWTRobot.java b/src/test/com/jogamp/opengl/test/junit/newt/TestFocus01SwingAWTRobot.java index 4de693c33..28e346a70 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/TestFocus01SwingAWTRobot.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/TestFocus01SwingAWTRobot.java @@ -40,7 +40,6 @@ import java.lang.reflect.InvocationTargetException; import javax.media.opengl.GLCapabilities; import javax.media.opengl.GLEventListener; -import javax.media.opengl.GLProfile; import javax.swing.JFrame; import java.util.ArrayList; @@ -52,7 +51,7 @@ import org.junit.Test; import com.jogamp.newt.awt.NewtCanvasAWT; import com.jogamp.newt.opengl.GLWindow; import com.jogamp.opengl.util.Animator; -import com.jogamp.opengl.test.junit.jogl.demos.es1.RedSquareES1; +import com.jogamp.opengl.test.junit.jogl.demos.es2.RedSquareES2; import com.jogamp.opengl.test.junit.util.*; @@ -93,7 +92,7 @@ public class TestFocus01SwingAWTRobot extends UITestCase { // Create a window. GLWindow glWindow1 = GLWindow.create(glCaps); glWindow1.setTitle("testNewtChildFocus"); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); TestListenerCom01AWT.setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); NEWTFocusAdapter glWindow1FA = new NEWTFocusAdapter("GLWindow1"); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/TestFocus02SwingAWTRobot.java b/src/test/com/jogamp/opengl/test/junit/newt/TestFocus02SwingAWTRobot.java index ac6300729..dd1827102 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/TestFocus02SwingAWTRobot.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/TestFocus02SwingAWTRobot.java @@ -54,7 +54,7 @@ import com.jogamp.newt.awt.NewtCanvasAWT; import java.io.IOException; import com.jogamp.opengl.test.junit.util.*; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; public class TestFocus02SwingAWTRobot extends UITestCase { static int width, height; @@ -91,7 +91,7 @@ public class TestFocus02SwingAWTRobot extends UITestCase { */ GLWindow glWindow1 = GLWindow.create(glCaps); glWindow1.setTitle("testWindowParenting01CreateVisibleDestroy"); - GLEventListener demo1 = new Gears(); + GLEventListener demo1 = new GearsES2(); glWindow1.addGLEventListener(demo1); NEWTFocusAdapter glWindow1FA = new NEWTFocusAdapter("GLWindow1"); glWindow1.addWindowListener(glWindow1FA); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/TestGLWindows00NEWT.java b/src/test/com/jogamp/opengl/test/junit/newt/TestGLWindows00NEWT.java index 0a5633900..5c42f2b16 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/TestGLWindows00NEWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/TestGLWindows00NEWT.java @@ -39,7 +39,7 @@ import com.jogamp.newt.opengl.*; import java.io.IOException; import com.jogamp.opengl.test.junit.util.UITestCase; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; import javax.media.nativewindow.AbstractGraphicsDevice; @@ -74,7 +74,7 @@ public class TestGLWindows00NEWT extends UITestCase { } glWindow.setUpdateFPSFrames(1, null); - GLEventListener demo = new Gears(); + GLEventListener demo = new GearsES2(); glWindow.addGLEventListener(demo); glWindow.setSize(512, 512); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/TestGLWindows01NEWT.java b/src/test/com/jogamp/opengl/test/junit/newt/TestGLWindows01NEWT.java index 21e3d93cd..45a0b0b13 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/TestGLWindows01NEWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/TestGLWindows01NEWT.java @@ -41,7 +41,7 @@ import java.io.IOException; import com.jogamp.opengl.test.junit.util.UITestCase; import com.jogamp.opengl.test.junit.util.MiscUtils; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; public class TestGLWindows01NEWT extends UITestCase { static GLProfile glp; @@ -82,7 +82,7 @@ public class TestGLWindows01NEWT extends UITestCase { Assert.assertEquals(false,glWindow.isVisible()); Assert.assertEquals(false,glWindow.isNativeValid()); - GLEventListener demo = new Gears(); + GLEventListener demo = new GearsES2(); setDemoFields(demo, glWindow); if(!addGLEventListenerAfterVisible) { glWindow.addGLEventListener(demo); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/TestListenerCom01AWT.java b/src/test/com/jogamp/opengl/test/junit/newt/TestListenerCom01AWT.java index b997cd393..15151fa2c 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/TestListenerCom01AWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/TestListenerCom01AWT.java @@ -28,37 +28,23 @@ package com.jogamp.opengl.test.junit.newt; -import java.lang.reflect.*; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - import org.junit.Assert; -import org.junit.Before; import org.junit.BeforeClass; -import org.junit.After; -import org.junit.AfterClass; import org.junit.Test; -import java.awt.Button; -import java.awt.BorderLayout; -import java.awt.Canvas; import java.awt.Frame; import javax.media.opengl.*; -import javax.media.nativewindow.*; import com.jogamp.opengl.util.Animator; import com.jogamp.newt.*; -import com.jogamp.newt.event.*; import com.jogamp.newt.opengl.*; import com.jogamp.newt.awt.NewtCanvasAWT; import java.io.IOException; import com.jogamp.opengl.test.junit.util.*; -import com.jogamp.opengl.test.junit.jogl.demos.es1.RedSquareES1; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; public class TestListenerCom01AWT extends UITestCase { static int width, height; @@ -80,7 +66,7 @@ public class TestListenerCom01AWT extends UITestCase { System.out.println("durationPerTest "+durationPerTest); - GLEventListener demo = new Gears(); + GLEventListener demo = new GearsES2(); setDemoFields(demo, glWindow, false); glWindow.addGLEventListener(demo); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/TestRemoteGLWindows01NEWT.java b/src/test/com/jogamp/opengl/test/junit/newt/TestRemoteGLWindows01NEWT.java index 70d08d2d4..578aa5556 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/TestRemoteGLWindows01NEWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/TestRemoteGLWindows01NEWT.java @@ -42,7 +42,7 @@ import com.jogamp.newt.opengl.*; import java.io.IOException; import com.jogamp.opengl.test.junit.util.UITestCase; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; import javax.media.nativewindow.AbstractGraphicsDevice; import javax.media.nativewindow.NativeWindowException; @@ -100,7 +100,7 @@ public class TestRemoteGLWindows01NEWT extends UITestCase { Animator animator = new Animator(); GLCapabilities caps = new GLCapabilities(glp); Assert.assertNotNull(caps); - GLWindow window1 = createWindow(null, caps, new Gears(1)); // local with vsync + GLWindow window1 = createWindow(null, caps, new GearsES2(1)); // local with vsync Assert.assertEquals(true,window1.isNativeValid()); Assert.assertEquals(true,window1.isVisible()); AbstractGraphicsDevice device1 = window1.getScreen().getDisplay().getGraphicsDevice(); @@ -125,7 +125,7 @@ public class TestRemoteGLWindows01NEWT extends UITestCase { System.err.println(""); System.err.println("GLProfiles window2: "+device2.getConnection()+": "+GLProfile.glAvailabilityToString(device2)); screen2 = NewtFactory.createScreen(display2, 0); // screen 0 - window2 = createWindow(screen2, caps, new Gears(0)); // remote, no vsync + window2 = createWindow(screen2, caps, new GearsES2(0)); // remote, no vsync } catch (NativeWindowException nwe) { System.err.println(nwe); Assume.assumeNoException(nwe); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/TestWindowClosingProtocol01AWT.java b/src/test/com/jogamp/opengl/test/junit/newt/TestWindowClosingProtocol01AWT.java index e6e8a5be0..3fc9b749a 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/TestWindowClosingProtocol01AWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/TestWindowClosingProtocol01AWT.java @@ -42,7 +42,8 @@ import javax.media.opengl.GLCapabilities; import javax.media.opengl.GLProfile; import javax.media.opengl.awt.GLCanvas; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; + import com.jogamp.opengl.test.junit.util.AWTRobotUtil; import com.jogamp.opengl.test.junit.util.UITestCase; @@ -55,7 +56,7 @@ public class TestWindowClosingProtocol01AWT extends UITestCase { GLProfile glp = GLProfile.getDefault(); GLCapabilities caps = new GLCapabilities(glp); final GLCanvas glCanvas = new GLCanvas(caps); - glCanvas.addGLEventListener(new Gears()); + glCanvas.addGLEventListener(new GearsES2()); SwingUtilities.invokeLater(new Runnable() { public void run() { frame.add(glCanvas); @@ -104,7 +105,7 @@ public class TestWindowClosingProtocol01AWT extends UITestCase { GLProfile glp = GLProfile.getDefault(); GLCapabilities caps = new GLCapabilities(glp); GLCanvas glCanvas = new GLCanvas(caps); - glCanvas.addGLEventListener(new Gears()); + glCanvas.addGLEventListener(new GearsES2()); frame.getContentPane().add(glCanvas); frame.pack(); frame.setSize(512, 512); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/TestWindowClosingProtocol02NEWT.java b/src/test/com/jogamp/opengl/test/junit/newt/TestWindowClosingProtocol02NEWT.java index 942f88e64..8ad52cae7 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/TestWindowClosingProtocol02NEWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/TestWindowClosingProtocol02NEWT.java @@ -40,7 +40,8 @@ import javax.media.opengl.GLProfile; import com.jogamp.newt.opengl.GLWindow; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; + import com.jogamp.opengl.test.junit.util.AWTRobotUtil; import com.jogamp.opengl.test.junit.util.UITestCase; @@ -53,7 +54,7 @@ public class TestWindowClosingProtocol02NEWT extends UITestCase { final GLWindow glWindow = GLWindow.create(caps); final AWTRobotUtil.WindowClosingListener windowClosingListener = AWTRobotUtil.addClosingListener(glWindow); - glWindow.addGLEventListener(new Gears()); + glWindow.addGLEventListener(new GearsES2()); glWindow.setSize(512, 512); glWindow.setVisible(true); Assert.assertEquals(true, glWindow.isVisible()); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/TestWindowClosingProtocol03NewtAWT.java b/src/test/com/jogamp/opengl/test/junit/newt/TestWindowClosingProtocol03NewtAWT.java index f850da14d..c8a2327a4 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/TestWindowClosingProtocol03NewtAWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/TestWindowClosingProtocol03NewtAWT.java @@ -42,7 +42,8 @@ import javax.media.nativewindow.WindowClosingProtocol; import javax.media.opengl.GLCapabilities; import javax.media.opengl.GLProfile; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; + import com.jogamp.opengl.test.junit.util.AWTRobotUtil; import com.jogamp.opengl.test.junit.util.UITestCase; @@ -57,7 +58,7 @@ public class TestWindowClosingProtocol03NewtAWT extends UITestCase { final GLWindow glWindow = GLWindow.create(caps); final AWTRobotUtil.WindowClosingListener windowClosingListener = AWTRobotUtil.addClosingListener(glWindow); - glWindow.addGLEventListener(new Gears()); + glWindow.addGLEventListener(new GearsES2()); NewtCanvasAWT newtCanvas = new NewtCanvasAWT(glWindow); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01NEWT.java b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01NEWT.java index 01356e9d0..1a6a05be1 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01NEWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01NEWT.java @@ -42,8 +42,8 @@ import com.jogamp.newt.opengl.*; import java.io.IOException; import com.jogamp.opengl.test.junit.util.*; -import com.jogamp.opengl.test.junit.jogl.demos.es1.RedSquareES1; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.RedSquareES2; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; public class TestParenting01NEWT extends UITestCase { static int width, height; @@ -82,7 +82,7 @@ public class TestParenting01NEWT extends UITestCase { glWindow1.setTitle("testWindowParenting01CreateVisibleDestroy"); glWindow1.setSize(640, 480); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); @@ -94,7 +94,7 @@ public class TestParenting01NEWT extends UITestCase { Assert.assertSame(screen,glWindow2.getScreen()); Assert.assertSame(display,glWindow2.getScreen().getDisplay()); glWindow2.setSize(320, 240); - GLEventListener demo2 = new Gears(); + GLEventListener demo2 = new GearsES2(); setDemoFields(demo2, glWindow2, false); glWindow2.addGLEventListener(demo2); @@ -304,7 +304,7 @@ public class TestParenting01NEWT extends UITestCase { GLWindow glWindow1 = GLWindow.create(glCaps); glWindow1.setTitle("testWindowParenting02ReparentTop2Win"); glWindow1.setSize(640, 480); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); screen1 = glWindow1.getScreen(); @@ -320,7 +320,7 @@ public class TestParenting01NEWT extends UITestCase { GLWindow glWindow2 = GLWindow.create(glCaps); glWindow2.setSize(320, 240); - GLEventListener demo2 = new Gears(); + GLEventListener demo2 = new GearsES2(); setDemoFields(demo2, glWindow2, false); glWindow2.addGLEventListener(demo2); Assert.assertSame(screen1, glWindow2.getScreen()); @@ -501,7 +501,7 @@ public class TestParenting01NEWT extends UITestCase { display1 = screen1.getDisplay(); glWindow1.setTitle("testWindowParenting03ReparentWin2Top"); glWindow1.setSize(640, 480); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); @@ -517,7 +517,7 @@ public class TestParenting01NEWT extends UITestCase { screen2 = glWindow2.getScreen(); display2 = screen2.getDisplay(); glWindow2.setSize(320, 240); - GLEventListener demo2 = new Gears(); + GLEventListener demo2 = new GearsES2(); setDemoFields(demo2, glWindow2, false); glWindow2.addGLEventListener(demo2); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01aAWT.java b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01aAWT.java index d52dbc2ef..2da3188e2 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01aAWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01aAWT.java @@ -28,39 +28,25 @@ package com.jogamp.opengl.test.junit.newt.parenting; -import java.lang.reflect.*; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - import org.junit.Assert; -import org.junit.Before; import org.junit.BeforeClass; -import org.junit.After; -import org.junit.AfterClass; import org.junit.Test; import java.awt.Button; import java.awt.BorderLayout; -import java.awt.Canvas; import java.awt.Container; import java.awt.Frame; -import java.awt.Dimension; import javax.media.opengl.*; -import javax.media.nativewindow.*; import com.jogamp.opengl.util.Animator; -import com.jogamp.newt.*; -import com.jogamp.newt.event.*; import com.jogamp.newt.opengl.*; import com.jogamp.newt.awt.NewtCanvasAWT; import java.io.IOException; import com.jogamp.opengl.test.junit.util.*; -import com.jogamp.opengl.test.junit.jogl.demos.es1.RedSquareES1; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.RedSquareES2; public class TestParenting01aAWT extends UITestCase { static int width, height; @@ -78,18 +64,13 @@ public class TestParenting01aAWT extends UITestCase { @Test public void testWindowParenting01CreateVisibleDestroy1() throws InterruptedException { - int x = 0; - int y = 0; - - NEWTEventFiFo eventFifo = new NEWTEventFiFo(); - GLWindow glWindow1 = GLWindow.create(glCaps); Assert.assertNotNull(glWindow1); Assert.assertEquals(false, glWindow1.isVisible()); Assert.assertEquals(false, glWindow1.isNativeValid()); Assert.assertNull(glWindow1.getParent()); glWindow1.setTitle("testWindowParenting01CreateVisibleDestroy"); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); @@ -149,17 +130,12 @@ public class TestParenting01aAWT extends UITestCase { @Test public void testWindowParenting02CreateVisibleDestroy2Defered() throws InterruptedException { - int x = 0; - int y = 0; - - NEWTEventFiFo eventFifo = new NEWTEventFiFo(); - GLWindow glWindow1 = GLWindow.create(glCaps); Assert.assertNotNull(glWindow1); Assert.assertEquals(false, glWindow1.isVisible()); Assert.assertEquals(false, glWindow1.isNativeValid()); Assert.assertNull(glWindow1.getParent()); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); @@ -194,13 +170,8 @@ public class TestParenting01aAWT extends UITestCase { @Test public void testWindowParenting02CreateVisibleDestroy3Odd() throws InterruptedException { - int x = 0; - int y = 0; - - NEWTEventFiFo eventFifo = new NEWTEventFiFo(); - GLWindow glWindow1 = GLWindow.create(glCaps); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); @@ -232,13 +203,8 @@ public class TestParenting01aAWT extends UITestCase { @Test public void testWindowParenting03ReparentNewtWin2Top() throws InterruptedException { - int x = 0; - int y = 0; - - NEWTEventFiFo eventFifo = new NEWTEventFiFo(); - GLWindow glWindow1 = GLWindow.create(glCaps); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); @@ -283,13 +249,8 @@ public class TestParenting01aAWT extends UITestCase { @Test public void testWindowParenting04ReparentNewtWin2TopLayouted() throws InterruptedException { - int x = 0; - int y = 0; - - NEWTEventFiFo eventFifo = new NEWTEventFiFo(); - GLWindow glWindow1 = GLWindow.create(glCaps); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); @@ -339,14 +300,9 @@ public class TestParenting01aAWT extends UITestCase { @Test public void testWindowParenting05ReparentAWTWinHopFrame2Frame() throws InterruptedException { - int x = 0; - int y = 0; - - NEWTEventFiFo eventFifo = new NEWTEventFiFo(); - GLWindow glWindow1 = GLWindow.create(glCaps); glWindow1.setUndecorated(true); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01bAWT.java b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01bAWT.java index 28a48d574..da556b3c6 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01bAWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01bAWT.java @@ -28,26 +28,15 @@ package com.jogamp.opengl.test.junit.newt.parenting; -import java.lang.reflect.*; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - import org.junit.Assert; -import org.junit.Before; import org.junit.BeforeClass; -import org.junit.After; -import org.junit.AfterClass; import org.junit.Test; import java.awt.Button; import java.awt.BorderLayout; -import java.awt.Canvas; import java.awt.Frame; -import java.awt.Dimension; import javax.media.opengl.*; -import javax.media.nativewindow.*; import com.jogamp.opengl.util.Animator; import com.jogamp.opengl.util.FPSAnimator; @@ -59,8 +48,7 @@ import com.jogamp.newt.awt.NewtCanvasAWT; import java.io.IOException; import com.jogamp.opengl.test.junit.util.*; -import com.jogamp.opengl.test.junit.jogl.demos.es1.RedSquareES1; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.RedSquareES2; public class TestParenting01bAWT extends UITestCase { static int width, height; @@ -86,14 +74,9 @@ public class TestParenting01bAWT extends UITestCase { } public void testWindowParenting05ReparentAWTWinHopFrame2FrameImpl(int fps) throws InterruptedException { - int x = 0; - int y = 0; - - NEWTEventFiFo eventFifo = new NEWTEventFiFo(); - GLWindow glWindow1 = GLWindow.create(glCaps); glWindow1.setUndecorated(true); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01cAWT.java b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01cAWT.java index 5052f0515..4477c3f8e 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01cAWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01cAWT.java @@ -28,38 +28,25 @@ package com.jogamp.opengl.test.junit.newt.parenting; -import java.lang.reflect.*; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - import org.junit.Assert; -import org.junit.Before; import org.junit.BeforeClass; -import org.junit.After; -import org.junit.AfterClass; import org.junit.Test; import java.awt.Button; import java.awt.BorderLayout; -import java.awt.Canvas; import java.awt.Container; import java.awt.Frame; -import java.awt.Dimension; import javax.media.opengl.*; -import javax.media.nativewindow.*; import com.jogamp.newt.*; -import com.jogamp.newt.event.*; import com.jogamp.newt.opengl.*; import com.jogamp.newt.awt.NewtCanvasAWT; import java.io.IOException; import com.jogamp.opengl.test.junit.util.*; -import com.jogamp.opengl.test.junit.jogl.demos.es1.RedSquareES1; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.RedSquareES2; public class TestParenting01cAWT extends UITestCase { static int width, height; @@ -75,19 +62,15 @@ public class TestParenting01cAWT extends UITestCase { @Test public void testWindowParenting01CreateVisibleDestroy1() throws InterruptedException { - int x = 0; - int y = 0; int i; - NEWTEventFiFo eventFifo = new NEWTEventFiFo(); - GLWindow glWindow1 = GLWindow.create(glCaps); Assert.assertNotNull(glWindow1); Assert.assertEquals(false, glWindow1.isVisible()); Assert.assertEquals(false, glWindow1.isNativeValid()); Assert.assertNull(glWindow1.getParent()); glWindow1.setTitle("testWindowParenting01CreateVisibleDestroy"); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); @@ -142,14 +125,9 @@ public class TestParenting01cAWT extends UITestCase { @Test public void testWindowParenting05ReparentAWTWinHopFrame2Frame() throws InterruptedException { - int x = 0; - int y = 0; - - NEWTEventFiFo eventFifo = new NEWTEventFiFo(); - GLWindow glWindow1 = GLWindow.create(glCaps); glWindow1.setUndecorated(true); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01cSwingAWT.java b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01cSwingAWT.java index 74a1cdb42..8ee91ddfb 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01cSwingAWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting01cSwingAWT.java @@ -45,14 +45,13 @@ import javax.media.opengl.*; import com.jogamp.opengl.util.Animator; import com.jogamp.newt.*; -import com.jogamp.newt.event.*; import com.jogamp.newt.opengl.*; import com.jogamp.newt.awt.NewtCanvasAWT; import java.io.IOException; import com.jogamp.opengl.test.junit.util.*; -import com.jogamp.opengl.test.junit.jogl.demos.es1.RedSquareES1; +import com.jogamp.opengl.test.junit.jogl.demos.es2.RedSquareES2; public class TestParenting01cSwingAWT extends UITestCase { static int width, height; @@ -78,7 +77,7 @@ public class TestParenting01cSwingAWT extends UITestCase { Assert.assertEquals(false, glWindow1.isNativeValid()); Assert.assertNull(glWindow1.getParent()); glWindow1.setTitle("testWindowParenting01CreateVisibleDestroy"); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); Animator animator1 = new Animator(glWindow1); @@ -189,7 +188,7 @@ public class TestParenting01cSwingAWT extends UITestCase { Assert.assertEquals(false, glWindow1.isNativeValid()); Assert.assertNull(glWindow1.getParent()); glWindow1.setTitle("testWindowParenting01CreateVisibleDestroy"); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); Animator animator1 = new Animator(glWindow1); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting02NEWT.java b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting02NEWT.java index a85addd91..fc079f357 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting02NEWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting02NEWT.java @@ -29,21 +29,12 @@ package com.jogamp.opengl.test.junit.newt.parenting; -import java.lang.reflect.*; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - import org.junit.Assert; -import org.junit.Before; import org.junit.BeforeClass; -import org.junit.After; -import org.junit.AfterClass; import org.junit.Test; import javax.media.opengl.*; import javax.media.nativewindow.*; -import javax.media.nativewindow.*; import com.jogamp.newt.*; import com.jogamp.newt.event.*; @@ -52,8 +43,8 @@ import com.jogamp.newt.opengl.*; import java.io.IOException; import com.jogamp.opengl.test.junit.util.*; -import com.jogamp.opengl.test.junit.jogl.demos.es1.RedSquareES1; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.RedSquareES2; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; public class TestParenting02NEWT extends UITestCase { static int width, height; @@ -122,7 +113,7 @@ public class TestParenting02NEWT extends UITestCase { glWindow1.addKeyListener(new TraceKeyAdapter(new KeyAction(eventFifo))); glWindow1.addWindowListener(new TraceWindowAdapter()); - GLEventListener demo1 = new RedSquareES1(); + GLEventListener demo1 = new RedSquareES2(); setDemoFields(demo1, window1, glWindow1, false); // glWindow1.addGLEventListener(demo1); @@ -144,7 +135,7 @@ public class TestParenting02NEWT extends UITestCase { glWindow2.addWindowListener(new TraceWindowAdapter(new WindowAction(eventFifo))); // glWindow2.addMouseListener(new TraceMouseAdapter()); - GLEventListener demo2 = new Gears(); + GLEventListener demo2 = new GearsES2(); setDemoFields(demo2, window2, glWindow2, false); // glWindow2.addGLEventListener(demo2); diff --git a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting03AWT.java b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting03AWT.java index 9ad592c02..2ce622312 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting03AWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting03AWT.java @@ -51,7 +51,7 @@ import com.jogamp.newt.awt.NewtCanvasAWT; import java.io.IOException; import com.jogamp.opengl.test.junit.util.*; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; public class TestParenting03AWT extends UITestCase { static Dimension size; @@ -79,7 +79,7 @@ public class TestParenting03AWT extends UITestCase { NewtCanvasAWT newtCanvasAWT1 = new NewtCanvasAWT(glWindow1); newtCanvasAWT1.setPreferredSize(size); - GLEventListener demo1 = new Gears(1); + GLEventListener demo1 = new GearsES2(1); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); final NewtCanvasAWT f_newtCanvasAWT1 = newtCanvasAWT1; diff --git a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting03bAWT.java b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting03bAWT.java index 04663bfb2..1f2259d1d 100644 --- a/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting03bAWT.java +++ b/src/test/com/jogamp/opengl/test/junit/newt/parenting/TestParenting03bAWT.java @@ -51,7 +51,7 @@ import com.jogamp.newt.awt.NewtCanvasAWT; import java.io.IOException; import com.jogamp.opengl.test.junit.util.*; -import com.jogamp.opengl.test.junit.jogl.demos.gl2.Gears; +import com.jogamp.opengl.test.junit.jogl.demos.es2.GearsES2; public class TestParenting03bAWT extends UITestCase { static Dimension size; @@ -77,7 +77,7 @@ public class TestParenting03bAWT extends UITestCase { NewtCanvasAWT newtCanvasAWT1 = new NewtCanvasAWT(glWindow1); newtCanvasAWT1.setPreferredSize(size); - GLEventListener demo1 = new Gears(1); + GLEventListener demo1 = new GearsES2(1); setDemoFields(demo1, glWindow1, false); glWindow1.addGLEventListener(demo1); final NewtCanvasAWT f_newtCanvasAWT1 = newtCanvasAWT1; @@ -108,7 +108,7 @@ public class TestParenting03bAWT extends UITestCase { NewtCanvasAWT newtCanvasAWT2 = new NewtCanvasAWT(glWindow2); newtCanvasAWT2.setPreferredSize(size); - GLEventListener demo2 = new Gears(1); + GLEventListener demo2 = new GearsES2(1); setDemoFields(demo2, glWindow2, false); glWindow2.addGLEventListener(demo2); final NewtCanvasAWT f_newtCanvasAWT2 = newtCanvasAWT2; -- cgit v1.2.3