Professional Documents
Culture Documents
Pixel Blend
Pixel Blend
#ifdef GL_ES
precision mediump float;
#endif
uniform sampler2D al_tex; ///what we're drawing
uniform sampler2D base_tex; ///what is already drawn
float screenWidth=640.0;
float screenHeight=360.0;
void main()
{
if (al_use_tex) {
//get drawing colour
gl_FragColor = varying_color * texture2D(al_tex, varying_texcoord);
} else {
gl_FragColor = varying_color;
}