Jump to content
  • Advertisement
Sign in to follow this  
bobsaget

A perplexing error(Me/vs 2005/and a header file)

This topic is 3817 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

I was looking at other apis thanks to the last post and answers and decided to use some code from some free tutorials to try out. I used the opengl free book from opengl.org and used some of the code. I ran into an odd error though. When I would type in the header files #include <GL/glu.h> #include <GL/glut.h> #include <stdlib.h> #include <GL/gl.h> and debugged it gave me something I haven't seen before. It started throwing 100's of error messages at the gl.h file instead of the main project. Even removing the #include directory for it wouldn't stop it from debugging this file. Another time it gave error messages for the stdlib.h directory. What should I do? last time this happened when it only debugged a .h file it some how later stopped and allowed the program to continue. Thanks

Share this post


Link to post
Share on other sites
Advertisement
Assuming you mean that you were getting compiler errors, try putting #include <windows.h> before the OpenGL headers.

Share this post


Link to post
Share on other sites
The GL headers use things like function calling convention identifiers that are defined in windows.h, but don't actually include windows.h themselves. So in order for them to compile correctly, you need to include windows.h first. Don't ask me why the GL headers don't include windows.h, because I don't know.

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.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!