diff options
author | Ian Romanick <ian.d.romanick@intel.com> | 2010-08-23 09:34:10 -0700 |
---|---|---|
committer | Ian Romanick <ian.d.romanick@intel.com> | 2010-08-23 09:34:10 -0700 |
commit | 0060cdc9fa0110afa0398303d0c13f90658c0243 (patch) | |
tree | 993ffb3bef1671b98f74702559766977ea704b35 /tests/shaders/glsl-const-builtin-notEqual-04.shader_test | |
parent | a039ac66419a715e0ae04aee9390b28b7302c890 (diff) |
Add GLSL tests for constant evaluation of equal and notEqual
Currently all of the tests involving boolean inputs to either equal or
notEqual fail with an assertion failure in Mesa's glsl2 compiler.
Diffstat (limited to 'tests/shaders/glsl-const-builtin-notEqual-04.shader_test')
-rw-r--r-- | tests/shaders/glsl-const-builtin-notEqual-04.shader_test | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/tests/shaders/glsl-const-builtin-notEqual-04.shader_test b/tests/shaders/glsl-const-builtin-notEqual-04.shader_test new file mode 100644 index 000000000..5aca53a01 --- /dev/null +++ b/tests/shaders/glsl-const-builtin-notEqual-04.shader_test @@ -0,0 +1,24 @@ + +[require] +GL >= 2.0 +GLSL >= 1.20 + +[vertex shader file] +glsl-mvp.vert + +[fragment shader] +#version 120 +void main() +{ + const bvec4 res = notEqual(vec4(-2.0, 0.0, 0.123, -1000.5), + vec4(-2.4, 0.0, 0.456, 12.5)); + gl_FragColor = (res == bvec4(true, false, true, true)) + ? vec4(0.0, 1.0, 0.0, 1.0) : vec4(1.0, 0.0, 0.0, 1.0); +} + +[test] +clear color 0.0 0.0 0.0 0.0 +clear +ortho +draw rect 10 10 10 10 +probe rgb 15 15 0.0 1.0 0.0 |