skia2/resources/sksl/intrinsics/Radians.sksl

15 lines
608 B
Plaintext
Raw Normal View History

uniform half4 inputVal, expected;
uniform half4 colorGreen, colorRed;
half4 main(float2 coords) {
const half4 constVal = half4(0);
return (radians(inputVal.x) == expected.x &&
radians(inputVal.xy) == expected.xy &&
radians(inputVal.xyz) == expected.xyz &&
radians(inputVal.xyzw) == expected.xyzw &&
radians(constVal.x) == expected.x &&
radians(constVal.xy) == expected.xy &&
radians(constVal.xyz) == expected.xyz &&
radians(constVal.xyzw) == expected.xyzw) ? colorGreen : colorRed;
}