Added RGBA to grayscale conversion