GPUImagePicture: check that the memory layout is valid for using the CGImage directly in GL

This corrects the fault introduced by my previous commit enabling CGImages to be used directly in GL.
Merge pull request #1298 from karlvr/gpuimagepicture-redraw2

GPUImagePicture: check that the memory layout is valid