Installing GLUT for VC++ 2003/2005/2008/2010 on windows

Here, how to installing glut on your windows system, n i’ll update it soon

  1. Download glut library from Nate Robin’s web site http://www.xmission.com/~nate/glut.html
    Better choose the latest compiled binary : glut-3.7.6-bin.zip (117 KB)
    The zip file contains: glut32.dll, glut.h
  2. Put the glut32.dll into ur system directory (%SystemRoot%\system32\), in my case : C:\windows\system32
  3. Find the VC++ library and include path:
    Mine :
    1. library path : C:\Program Files\Microsoft Visual Studio 9.0\VC\lib put the glut32.lib into above directory
      Note on VS2003, C:/PROGRA~1/MICROS~1.NET/Vc7/lib/
    2. include path : C:\Program Files\Microsoft Visual Studio 9.0\VC\includewithin this directory create new folder called GL (optional) and put the glut.h into this directory.
      Note : on VS2003, C:/PROGRA~1/MICROS~1.NET/Vc7/include/
  4. Try compiling and running this code
  5. OK, thats all

Edit :
I have tried to install glut on codeblock and got this error when compiling it

C:/Program Files/Codeblocks/mingw/include/gl/glut.h:47: error: redeclaration of C++ built-in type 'short'
mingw32-make: *** [first.o] Error 1
line xxx typedef unsigned short wchar_t; 

To solve this problem, add

#include <windows.h>

before including any glut files

:)

Advertisements

One thought on “Installing GLUT for VC++ 2003/2005/2008/2010 on windows

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

w

Connecting to %s