shaders/scanlines-basic.frag
author František Kučera <franta-hg@frantovo.cz>
Sun, 03 Dec 2023 19:22:25 +0100
branchv_0
changeset 17 f53a040bdc89
parent 15 shaders/default.frag@1eb7cfefbeea
child 18 c4384f43c739
permissions -rw-r--r--
new shader: scanlines-basic.frag

#version 330 core

uniform  sampler2D  uTexture;
in       vec2       vTextureXY;
out      vec4       fColor;

void main(){
	fColor = texture(uTexture, vTextureXY).rgba;

	float lineCount = 260.;
	fColor.xyz *= abs(sin(radians(vTextureXY.y * 180. * lineCount)));
}