Simple interpolation to get the color and then applying to the grayscale image
#ifdef GL_ES precision lowp float; #endif varying vec2 v_texCoord; uniform vec4 u_desiredColor; uniform sampler2D u_texture; floatvec4 saturation; floatvec4 grayscale; void main() { grayscale = texture2D(u_texture, v_texCoord); saturation = (1.0,1.0,1.0,1.0) - grayscale; gl_FragColor = grayscale*(saturation * u_desiredColor + grayscale*vec4(1.0,1.0,1.0,1.0)); }