rhythmbullet/android/assets/shaders/combine.fsh

25 lines
514 B
Plaintext
Raw Normal View History

2017-09-03 08:29:33 +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;
uniform sampler2D u_texture1;
2018-09-04 01:39:26 +00:00
uniform sampler2D u_texture2;
2017-09-03 08:29:33 +00:00
void main() {
2018-09-04 01:39:26 +00:00
vec4 origColor = texture2D(u_texture, vTexCoord);
vec4 blurredColor = texture2D(u_texture1, vTexCoord);
vec4 lightFilterColor = texture2D(u_texture2, vTexCoord);
vec4 result;
result = origColor + blurredColor;
gl_FragColor = result*vColor;
2017-09-03 08:29:33 +00:00
}