made some changes to accomodate GLEW