Created
February 26, 2015 05:02
-
-
Save ericleong/c786c031b1767aab6f2f to your computer and use it in GitHub Desktop.
Fade Effect Fragment Shader
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#extension GL_OES_EGL_image_external : require | |
precision mediump float; | |
varying vec2 vTextureCoord; | |
uniform samplerExternalOES sTexture; | |
void main() { | |
vec4 color = texture2D(sTexture, vTextureCoord); | |
float r = 0.2 + 0.8 * color.r; | |
float g = 0.2 + 0.8 * color.g; | |
float b = 0.2 + 0.8 * color.b; | |
gl_FragColor = vec4(r, g, b, 1.0); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment