Using GLEW to use OpenGL extensions under Windows

后端 未结 3 1057
日久生厌
日久生厌 2020-11-30 00:40

I\'ve been using OpenGL extensions on Windows the painful way. Is GLEW the easier way to go? How do I get started with it?

3条回答
  •  情深已故
    2020-11-30 01:14

    I lost some time, but finally I managed to get GLEW working. I'm using Windows7 (x64), Eclipse CDT and MinGW, and the way is that:

    Download MSYS (for MinGW) and rember to have MinGW installed correctly (PATH enviroinment variable set correctly): http://sourceforge.net/projects/mingw/files/MSYS/Base/msys-core/msys-1.0.10/MSYS-1.0.10.exe/download?use_mirror=freefr&download=

    Once MSYS installed, go to: http://glew.sourceforge.net/ and download the TGZ package, which is intended to use with UNIX systems

    Then open the package (you can use 7zip as well) and find the "Makefile". Open it and with a text editor (Notepad should work fine) find the row which contains "GLEW_DEST" and replace it with something like "GLEW_DEST ?= C:/MinGW"

    Now you are ready to go, open MSYS (C:\MinGW\msys\1.0\msys.bat in my case) and in the shell opened, go to the folder where the "Makefile" is.

    Then write a simple: "make install" and the work is done (at least for me it worked)

    PS: I also copy-pasted glew-1.10.0-win32\glew-1.10.0\bin\Release\Win32 file's into my System32 folder, and in Eclipse CDT I added the library "glew32" in the linker option and added a #include before #include

提交回复
热议问题