factored out image class, using OpenGL seemed to not make a difference