1 # This exercises a bug found in a Doom shader where the lessThan() comparison
2 # was only done against a single component of the mixed arithmetic expression
3 # rather than all four components.
8 [vertex shader passthrough]
17 gl_FragColor = vec4(0.0, 1.0, 0.0, 1.0);
19 if (any(lessThan(b.w + a.xyzw, vec4(0.0))))
20 gl_FragColor = vec4(1.0, 0.0, 0.0, 1.0);
24 clear color 0.1 0.1 0.1 0.1
27 uniform vec4 a 0.5 0.5 0.5 -1.0
28 uniform vec4 b 1.0 1.0 1.0 0.5
31 probe all rgba 1.0 0.0 0.0 1.0
33 uniform vec4 a 0.5 0.5 0.5 -0.5
34 uniform vec4 b 1.0 1.0 1.0 0.5
37 probe all rgba 0.0 1.0 0.0 1.0