rhythmbullet/android/assets/shaders/invert_frag.glsl
2017-06-07 21:53:40 -05:00

17 lines
316 B
GLSL
Executable File

#ifdef GL_ES
#define LOWP lowp
precision mediump float;
#else
#define LOWP
#endif
varying LOWP vec4 vColor;
varying vec2 vTexCoord;
uniform sampler2D u_texture;
void main() {
vec4 texColor = texture2D(u_texture, vTexCoord);
texColor.rgb = 1.0 - texColor.rgb;
gl_FragColor = texColor * vColor;
}