summaryrefslogtreecommitdiffstats
path: root/src/gui/doc/snippets/rhioffscreen/color.frag
blob: ad9d953d021deccc18e3d8222bb69d19998a1f70 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
//! [0]
#version 440

layout(location = 0) in vec3 v_color;
layout(location = 0) out vec4 fragColor;

layout(std140, binding = 0) uniform buf {
    mat4 mvp;
    float opacity;
};

void main()
{
    fragColor = vec4(v_color * opacity, opacity);
}
//! [0]