Captures opengl to images