aboutsummaryrefslogtreecommitdiffstats
path: root/src/test/com/jogamp/opengl
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2012-10-19 07:46:31 +0200
committerSven Gothel <[email protected]>2012-10-19 07:46:31 +0200
commit416c7fc1b90cd7b34c251268bb83ebeea61d17d6 (patch)
tree331fb09271fc49c0f876879f3d3577e27a7319ed /src/test/com/jogamp/opengl
parent1aea29bb5d253600213024fd2c12a91bf3599202 (diff)
NEWT / BCM-VC-IV: Fix transparency according to given capabilities
Tested manual w/ TestGearsES2NEWT on Raspberry Pi
Diffstat (limited to 'src/test/com/jogamp/opengl')
-rw-r--r--src/test/com/jogamp/opengl/test/junit/jogl/demos/es2/newt/TestGearsES2NEWT.java8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/test/com/jogamp/opengl/test/junit/jogl/demos/es2/newt/TestGearsES2NEWT.java b/src/test/com/jogamp/opengl/test/junit/jogl/demos/es2/newt/TestGearsES2NEWT.java
index a79c924d6..1620985c1 100644
--- a/src/test/com/jogamp/opengl/test/junit/jogl/demos/es2/newt/TestGearsES2NEWT.java
+++ b/src/test/com/jogamp/opengl/test/junit/jogl/demos/es2/newt/TestGearsES2NEWT.java
@@ -75,6 +75,7 @@ public class TestGearsES2NEWT extends UITestCase {
static long duration = 500; // ms
static boolean opaque = true;
+ static int forceAlpha = -1;
static boolean undecorated = false;
static boolean alwaysOnTop = false;
static boolean fullscreen = false;
@@ -257,6 +258,9 @@ public class TestGearsES2NEWT extends UITestCase {
System.err.println("Loop "+i+"/"+loops);
GLCapabilities caps = new GLCapabilities(forceES2 ? GLProfile.get(GLProfile.GLES2) : GLProfile.getGL2ES2());
caps.setBackgroundOpaque(opaque);
+ if(-1 < forceAlpha) {
+ caps.setAlphaBits(forceAlpha);
+ }
runTestGL(caps, undecorated);
if(loop_shutdown) {
GLProfile.shutdown();
@@ -274,6 +278,9 @@ public class TestGearsES2NEWT extends UITestCase {
duration = MiscUtils.atol(args[i], duration);
} else if(args[i].equals("-translucent")) {
opaque = false;
+ } else if(args[i].equals("-forceAlpha")) {
+ i++;
+ forceAlpha = MiscUtils.atoi(args[i], 0);
} else if(args[i].equals("-undecorated")) {
undecorated = true;
} else if(args[i].equals("-atop")) {
@@ -328,6 +335,7 @@ public class TestGearsES2NEWT extends UITestCase {
System.err.println("size "+wsize);
System.err.println("screen "+screenIdx);
System.err.println("translucent "+(!opaque));
+ System.err.println("forceAlpha "+forceAlpha);
System.err.println("undecorated "+undecorated);
System.err.println("atop "+alwaysOnTop);
System.err.println("fullscreen "+fullscreen);