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

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

uniform vec4 color1;
uniform vec4 color2;
uniform int size;

out vec4 fragColor;

void main()
{
	vec2 phase = mod(gl_FragCoord.xy, (size*2));

	if ((phase.x > size && phase.y < size) ||
		(phase.x < size && phase.y > size))
	{
		fragColor = color1;
	}
	else {
		fragColor = color2;
	}
}