PDA

View Full Version : error:can not open GL\glut.h



Lily
03-15-2001, 11:44 AM
It's my first time I use OpenGL today, I downloaded some sample code from the website and try to run it then got the above error. My OS is windowsME, I have linked the 3 .lib files from visual sutio\lib to my project. and I'm sure the glut.h file is there under GL. Could anyboday help me on this?
thanks in advance for your help, i really want to make it work.

mango
03-15-2001, 02:58 PM
Right, the hglut.h should be in a directory called GL in your include directory. Check that it looks OK in the editor.

I am not using MSVC but most compilers lets you change the default for the include dir. Check this also.

Bahamut_france
03-16-2001, 12:21 AM
Hi.

Go in Visual C++ directory. Copy glut.h (others: glu.h, gl.g, glaux.h, glui.h,......) in the directory:
.\includes\GL\
For lib (gl.lib, glu.lib, glut.lib) , look at:
.\lib\

Visual C++, in Setting Project, You must add librairies name in 'link' ,else VC doesn't want to link classes.

Now, in your first program, write:

#include <GL\gl.h>
#include <GL\glu.h>
#include <GL\glut.h>


That's all.