View Full Version : code in the OpenGL programming guide
11-05-2008, 02:04 AM
I'm a newbie in this domain,when reading the OpenGL programming guide,I find I can hardly run the code in the book successfully,that's very depressing,I wondered can anybody tell me how to begin with the OpenGL,you know,start with the setup of the environment or something else basic,thanks.Besides,English is not my Mother tongue,so if you think I did not express myself clearly,you can tell me,my mail is firstname.lastname@example.org.
11-05-2008, 02:24 AM
first, what is going wrong? describe the problem i.e linking erros or header files missing etc.
second, what IDE you use and what OS?
you better start with simple samples like NeHe. they have many projects prepared to startup, compile and run.
11-05-2008, 05:18 AM
I use visual studio 2005 to run the programs under windows xp .
there is one line of the errors:
d:\program files\vs\vc\platformsdk\include\gl\gl.h(1171) : error C2085: “APIENTRY”: not in the formal parameter list
all of those errors have"d:\program files\vs\vc\platformsdk\include\gl\gl.h"
11-05-2008, 05:39 AM
hmmm. is <winnt.h> included?
11-05-2008, 06:42 AM
ermm,you say <winnt.h>,do you mean header files dealing with the windows operation or <windows.h>?if the latter,yes
11-05-2008, 02:14 PM
Try the Code::Blocks (http://www.codeblocks.org) IDE. It comes with the free MinGW toolset (GCC compiler and a bunch of other binary utilities), and it works with OpenGL out of the box.
11-06-2008, 01:10 PM
try #include-ing the windows header file before you include gl.h
11-06-2008, 08:38 PM
Thank you,I forgot……
Powered by vBulletin® Version 4.2.3 Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.