aboutsummaryrefslogtreecommitdiffstats
path: root/examples/resources/textureshader.frag
blob: 8d916be6e2ed1cd3a4fa9b6640bbf6d7a3424471 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#version 450

layout(location = 0) in vec2 fragment_position;
layout(location = 1) in vec4 fragment_colour;
layout(location = 2) in vec2 fragment_uv;

layout(location = 0) out vec4 colour;
layout(location = 1) out vec4 colour2;

uniform sampler2D texture_sampler;

void main()
{
    vec4 texture_colour = texture(texture_sampler, fragment_uv);

    colour2 = vec4(1.f, 0.f, 0.f, 1.f);
    colour = texture_colour;
}