Subversion Repositories AndroidProjects

Rev

Rev 1686 | Blame | Compare with Previous | Last modification | View Log | RSS feed

#ifdef GL_ES
precision mediump float;
#endif

uniform sampler2D uDiffuse;
uniform float uLayer;

varying vec4 vColor;
varying vec2 vTexCoord;

void main()
{
        vec4 result = texture2D(uDiffuse, vTexCoord.xy);
        
        float startIntensity = 0.4;
        result.rgb *= startIntensity + clamp(uLayer * 2.0, 0.0, 1.0) * (1.0 - startIntensity);
        result.a *= (1.0-uLayer);
        gl_FragColor = result;
}