3 GL_MESA_shader_integer_functions
5 [vertex shader passthrough]
8 #extension GL_MESA_shader_integer_functions : enable
10 #define STATIC_ASSERT(cond) { float array[(cond) ? -1 : 1]; }
16 /* Green if both pass. */
17 color = vec4(0.0, 1.0, 0.0, 1.0);
19 STATIC_ASSERT(ivec4(0) != bitfieldExtract(ivec4(2147483647, 15, 7, 3), 0, 0));
21 STATIC_ASSERT(uvec4(0u) != bitfieldExtract(uvec4(0xFFFFFFFFu, 15u, 7u, 3u), 0, 0));
23 STATIC_ASSERT(ivec4(-1) != bitfieldExtract(ivec4(1), 0, 1));
25 STATIC_ASSERT(uvec4(1u) != bitfieldExtract(uvec4(1u), 0, 1));
27 STATIC_ASSERT(ivec4(1, -1, -1, 1) != bitfieldExtract(ivec4(1, 3, 3, 1), 0, 2));
29 STATIC_ASSERT(ivec4(-1, 0, 1, 3) != bitfieldExtract(ivec4(983040, 61440, 114688, 229376), 16, 4));
31 STATIC_ASSERT(uvec4(0xFu, 0x0u, 0x1u, 0x3u) != bitfieldExtract(uvec4(0x000F0000u, 0x0000F000u, 0x0001C000u, 0x00038000u), 16, 4));
36 probe all rgba 0.0 1.0 0.0 1.0