aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/test/com/jogamp/opengl/test/junit/jogl/demos/gl2es1/gears/newt/TestGearsGL2ES1NEWT.java8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/test/com/jogamp/opengl/test/junit/jogl/demos/gl2es1/gears/newt/TestGearsGL2ES1NEWT.java b/src/test/com/jogamp/opengl/test/junit/jogl/demos/gl2es1/gears/newt/TestGearsGL2ES1NEWT.java
index 43fa2852e..ffba7c050 100644
--- a/src/test/com/jogamp/opengl/test/junit/jogl/demos/gl2es1/gears/newt/TestGearsGL2ES1NEWT.java
+++ b/src/test/com/jogamp/opengl/test/junit/jogl/demos/gl2es1/gears/newt/TestGearsGL2ES1NEWT.java
@@ -53,7 +53,13 @@ public class TestGearsGL2ES1NEWT extends UITestCase {
@BeforeClass
public static void initClass() {
GLProfile.initSingleton(true);
- glp = GLProfile.getGL2ES1();
+ if(GLProfile.isAvailable(GLProfile.getDefaultEGLDevice(), GLProfile.GLES1)) {
+ // exact match
+ glp = GLProfile.get(GLProfile.getDefaultEGLDevice(), GLProfile.GLES1);
+ } else {
+ // default device, somehow ES1 compatible
+ glp = GLProfile.getGL2ES1();
+ }
Assert.assertNotNull(glp);
width = 512;
height = 512;