Changes to image processing functions to deal with grayscale images from
the Qcapture camera.