aboutsummaryrefslogtreecommitdiffstats
path: root/tests/manual/scenegraph_lancelot/data/shared/shaders/desaturate_rhi.frag
blob: a4299c6d686c56f253ac33f6737bb0d88974e381 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#version 440

layout(location = 0) in vec2 qt_TexCoord0;
layout(location = 0) out vec4 fragColor;
layout(binding = 1) uniform sampler2D source;

void main() {
    lowp vec4 c = texture(source, qt_TexCoord0);
    lowp float level = c.r * 0.3 + c.g * 0.59 + c.b * 0.11;

    fragColor = vec4(level, level, level, c.a);
}