marifx_m/shaders/glsl/mfx_bss_shift.fp
2019-01-03 18:27:49 +01:00

11 lines
331 B
GLSL

void main()
{
vec2 coord = TexCoord;
vec4 res = texture(InputTexture,coord);
vec2 bresl = textureSize(InputTexture,0);
vec2 bof = (1.0/bresl)*bssshiftradius;
res.g = texture(InputTexture,coord).g;
res.r = texture(InputTexture,coord+vec2(0,-bof.y)).r;
res.b = texture(InputTexture,coord+vec2(0,bof.y)).b;
FragColor = res;
}