varying vec2 v_vTexcoord;
varying vec4 v_vColour;

void main()
{
    vec4 col = texture2D(gm_BaseTexture, v_vTexcoord);
    float grey = dot(col.rgb, vec3(0.299, 0.587, 0.114));
    vec3 grey_col = vec3(grey, grey, grey);
    gl_FragColor = vec4(mix(col.rgb, grey_col, 0.5), col.a) * v_vColour;
}