Started adding some OpenGL error checking.