summaryrefslogtreecommitdiffstats
path: root/src/test/com
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/com')
-rw-r--r--src/test/com/jogamp/opengl/test/junit/jogl/demos/es2/shader/RedSquareShader.java14
-rw-r--r--src/test/com/jogamp/opengl/test/junit/jogl/demos/es2/shader/texsequence_xxx.fp1
2 files changed, 14 insertions, 1 deletions
diff --git a/src/test/com/jogamp/opengl/test/junit/jogl/demos/es2/shader/RedSquareShader.java b/src/test/com/jogamp/opengl/test/junit/jogl/demos/es2/shader/RedSquareShader.java
index cdbf3d9b8..07f3a97cb 100644
--- a/src/test/com/jogamp/opengl/test/junit/jogl/demos/es2/shader/RedSquareShader.java
+++ b/src/test/com/jogamp/opengl/test/junit/jogl/demos/es2/shader/RedSquareShader.java
@@ -35,6 +35,11 @@ public class RedSquareShader {
" precision mediump int;\n" +
"#endif\n" +
"\n" +
+ "#if __VERSION__ >= 130\n" +
+ " #define attribute in\n" +
+ " #define varying out\n" +
+ "#endif\n"+
+ "\n" +
"uniform mat4 mgl_PMVMatrix[2];\n" +
"attribute vec4 mgl_Vertex;\n" +
"attribute vec4 mgl_Color;\n" +
@@ -52,10 +57,17 @@ public class RedSquareShader {
" precision mediump int;\n" +
"#endif\n" +
"\n" +
+ "#if __VERSION__ >= 130\n" +
+ " #define varying in\n" +
+ " out vec4 mgl_FragColor;\n" +
+ "#else\n" +
+ " #define mgl_FragColor gl_FragColor\n" +
+ "#endif\n" +
+ "\n" +
"varying vec4 frontColor;\n" +
"\n" +
"void main (void)\n" +
"{\n" +
- " gl_FragColor = frontColor;\n" +
+ " mgl_FragColor = frontColor;\n" +
"}\n" ;
}
diff --git a/src/test/com/jogamp/opengl/test/junit/jogl/demos/es2/shader/texsequence_xxx.fp b/src/test/com/jogamp/opengl/test/junit/jogl/demos/es2/shader/texsequence_xxx.fp
index 5e7bd2879..e4f21f95f 100644
--- a/src/test/com/jogamp/opengl/test/junit/jogl/demos/es2/shader/texsequence_xxx.fp
+++ b/src/test/com/jogamp/opengl/test/junit/jogl/demos/es2/shader/texsequence_xxx.fp
@@ -3,6 +3,7 @@
#if __VERSION__ >= 130
#define varying in
out vec4 mgl_FragColor;
+ #define texture2D texture
#else
#define mgl_FragColor gl_FragColor
#endif