Fixed OpenGL implementation for windows.