2020-09-14 21:30:13 +00:00
|
|
|
|
2021-01-27 00:58:22 +00:00
|
|
|
out vec4 sk_FragColor;
|
2021-01-26 21:28:12 +00:00
|
|
|
uniform float unknownInput;
|
|
|
|
uniform vec4 colorRed;
|
|
|
|
uniform vec4 colorGreen;
|
2021-01-22 14:51:13 +00:00
|
|
|
bool test_int() {
|
2021-01-26 21:28:12 +00:00
|
|
|
int unknown = int(unknownInput);
|
2021-01-22 14:51:13 +00:00
|
|
|
bool ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = true;
|
|
|
|
ok = ivec4(unknown) == ivec4(unknown);
|
|
|
|
ok = ok && ivec4(unknown) == ivec4(unknown);
|
|
|
|
ok = ok && ivec4(unknown) == ivec4(unknown);
|
|
|
|
ok = ok && ivec4(unknown) == ivec4(unknown);
|
|
|
|
ok = ok && ivec4(unknown) == ivec4(unknown);
|
|
|
|
ivec4 val = ivec4(unknown);
|
|
|
|
val += ivec4(1);
|
|
|
|
val -= ivec4(1);
|
2021-02-06 00:12:27 +00:00
|
|
|
val = val + ivec4(1);
|
|
|
|
val = val - ivec4(1);
|
2021-01-22 14:51:13 +00:00
|
|
|
ok = ok && val == ivec4(unknown);
|
|
|
|
val *= ivec4(2);
|
|
|
|
val /= ivec4(2);
|
2021-02-06 00:12:27 +00:00
|
|
|
val = val * ivec4(2);
|
|
|
|
val = val / ivec4(2);
|
2021-01-22 14:51:13 +00:00
|
|
|
ok = ok && val == ivec4(unknown);
|
|
|
|
return ok;
|
|
|
|
}
|
|
|
|
vec4 main() {
|
2021-01-26 21:28:12 +00:00
|
|
|
float _1_unknown = unknownInput;
|
2021-01-22 14:51:13 +00:00
|
|
|
bool _2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = true;
|
|
|
|
_2_ok = vec4(_1_unknown) == vec4(_1_unknown);
|
|
|
|
_2_ok = _2_ok && vec4(_1_unknown) == vec4(_1_unknown);
|
|
|
|
_2_ok = _2_ok && vec4(_1_unknown) == vec4(_1_unknown);
|
|
|
|
_2_ok = _2_ok && vec4(_1_unknown) == vec4(_1_unknown);
|
|
|
|
_2_ok = _2_ok && vec4(_1_unknown) == vec4(_1_unknown);
|
|
|
|
vec4 _3_val = vec4(_1_unknown);
|
|
|
|
_3_val += vec4(1.0);
|
|
|
|
_3_val -= vec4(1.0);
|
2021-02-06 00:12:27 +00:00
|
|
|
_3_val = _3_val + vec4(1.0);
|
|
|
|
_3_val = _3_val - vec4(1.0);
|
2021-01-22 14:51:13 +00:00
|
|
|
_2_ok = _2_ok && _3_val == vec4(_1_unknown);
|
|
|
|
_3_val *= vec4(2.0);
|
|
|
|
_3_val /= vec4(2.0);
|
2021-02-06 00:12:27 +00:00
|
|
|
_3_val = _3_val * vec4(2.0);
|
|
|
|
_3_val = _3_val / vec4(2.0);
|
2021-01-22 14:51:13 +00:00
|
|
|
_2_ok = _2_ok && _3_val == vec4(_1_unknown);
|
2021-01-26 21:28:12 +00:00
|
|
|
return _2_ok && test_int() ? colorGreen : colorRed;
|
2020-11-05 16:59:10 +00:00
|
|
|
|
2020-09-14 21:30:13 +00:00
|
|
|
}
|