varying vec2 v_texCoord;
vec4 srcColor;

void main(void)
{
    float intensity;
    srcColor = texture2D(CC_Texture0, v_texCoord);
    /* You can do further changes here, if you want. */
    intensity = (srcColor.r + srcColor.g + srcColor.b) / 4.0;

    gl_FragColor = vec4( intensity, intensity, intensity, srcColor.a );
}