rhythmbullet/android/assets/shaders/invert_frag.glsl

18 lines
318 B
Plaintext
Raw Normal View History

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