Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gpu_shader_image_shuffle_color_frag.glsl « shaders « gpu « blender « source - git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 64662247d69664633f51aba3e367e4b6350b9fc9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16

in vec2 texCoord_interp;
out vec4 fragColor;

uniform sampler2D image;
uniform vec4 color;
uniform vec4 shuffle;

void main()
{
	vec4 sample = texture(image, texCoord_interp);
	fragColor = vec4(sample.r * shuffle.r +
	                 sample.g * shuffle.g +
	                 sample.b * shuffle.b +
	                 sample.a * shuffle.a) * color;
}