Slide 64
Slide 64 text
©MIXI
Fragment shader
#extension GL_OES_EGL_image_external : require
varying vec2 vTextureCoord;
uniform samplerExternalOES sTexture;
void main() {
vec4 color = texture2D(sTexture, vTextureCoord);
float alpha = max(color.r, max(color.g, color.b));
gl_FragColor = vec4(color.r, color.g, color.b, alpha);
}
: Big Buck Bunny, © 2008, Blender Foundation / www.bigbuckbunny.org