Fixed hasOpenGL()
Added OpenGL error methods