Jump to content
  • Advertisement
Sign in to follow this  
CombatHammie

[Solved] Visual C++ Express/OpenGL... what am I missing.

This topic is 4176 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

OK, so I installed the PSDK. Added the directories... all as instructed. And yet I still get errors when trying to compile anything that has <gl.h> or <gl\...> in it. What did I miss? EDIT: Here are all the screens I can think of: [Edited by - CombatHammie on December 16, 2006 9:46:22 PM]

Share this post


Link to post
Share on other sites
Advertisement

1>------ Build started: Project: Simple, Configuration: Debug Win32 ------
1>Compiling...
1>Simple.cpp
1>c:\...\simple\simple.cpp(1) : fatal error C1083: Cannot open include file: 'gl\glut.h': No such file or directory
1>Build log was saved at "...\Debug\BuildLog.htm"
1>Simple - 1 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========


#pragma comment(lib, "opengl32.lib") yields the same result.

Share this post


Link to post
Share on other sites
search you hard drive for gl.h Is it there?

If it is there, you need to go into your project settings and enter the path to that file under "additional include directories" in the properties section of the compiler settings.

right click on the project in the solution explorer -> properties -> C/C++ -> General -> Additional Include Directories.

Installing the SDK should have set the classpath environment variable up correctly but whatevs. just make sure the gl.h header actually exists on your machine. =)

-me

Share this post


Link to post
Share on other sites
GLUT has nothing to do with standart GL or GLU headers.
GLUT is completly independent library.
So it must be installed independently from PSDK.
Hint: get FreeGLUT - http://freeglut.sourceforge.net/

Share this post


Link to post
Share on other sites
The Microsoft PSDK doesn't come with glut, you need to download it online. After you download it just copy the appropriate files into the appropriate folders within your PSDK (for example put the glut.h file with the PSDK "gl" folder) so you don't have to be bothered to add additional include folders in your project settings.

Share this post


Link to post
Share on other sites
Thanks bubu, I completely forgot that GLUT is seperate.

Nevertheless, it's just a side thing. GL.h IS on the machine (in the PSDK) folder.

And no, it looks like classpath environment variables were NOT set automatically during the installation. So the question is what to do now.


[Edited by - CombatHammie on December 15, 2006 6:11:52 PM]

Share this post


Link to post
Share on other sites
Quote:
Original post by CombatHammie
Thanks bubu, I completely forgot that GLUT is seperate.

Nevertheless, it's just a side thing. GL.h IS on the machine (in the PSDK) folder.

And no, it looks like classpath environment variables were NOT set automatically during the installation. So the question is what to do now.


After you've got glut.h being found what errors do you get? If it says you're missing gl.h or glu.h simply go to Tools->Options, then under the Projects and Solutions node click on VC++ Directories and then add the directories to the PSDK under the right list ("Executable Files", "Include Files", etc.) [smile]

For example, I had to manually add "C:\Program Files\Microsoft Platform SDK\Include" into my "Include Files" list.

Share this post


Link to post
Share on other sites
Quote:
Original post by common
Quote:
Original post by CombatHammie
Thanks bubu, I completely forgot that GLUT is seperate.

Nevertheless, it's just a side thing. GL.h IS on the machine (in the PSDK) folder.

And no, it looks like classpath environment variables were NOT set automatically during the installation. So the question is what to do now.


After you've got glut.h being found what errors do you get? If it says you're missing gl.h or glu.h simply go to Tools->Options, then under the Projects and Solutions node click on VC++ Directories and then add the directories to the PSDK under the right list ("Executable Files", "Include Files", etc.) [smile]

For example, I had to manually add "C:\Program Files\Microsoft Platform SDK\Include" into my "Include Files" list.




I'll deal with glut later, right now I can't even compile anything with gl.h

I added the directories as needed. There is a file that has to be edited, I know for sure that that's the reason behind the problem. What are the files that have to be added? (opengl32.lib is one of them)

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!