Jump to content
  • Advertisement
Sign in to follow this  
Gumgo

OpenGL Trouble compiling

This topic is 4258 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'm pretty new to OpenGL, and keep getting a ton of errors whenever I try to compile. I'm including these files: #include <gl\gl.h> #include <gl\glu.h> #include <gl\glaux.h> And linking the libraries: opengl32.lib glu32.lib glaux.lib For some reason, I get tons and tons of errors that say things like these: C:\Program Files\Microsoft Visual Studio .NET\Vc7\PlatformSDK\Include\gl\GL.h(1153): error C2086: 'int APIENTRY' : redefinition C:\Program Files\Microsoft Visual Studio .NET\Vc7\PlatformSDK\Include\gl\GL.h(1168): error C2144: syntax error : 'void' should be preceded by ';' C:\Program Files\Microsoft Visual Studio .NET\Vc7\PlatformSDK\Include\gl\GL.h(1153): error C2146: syntax error : missing ';' before identifier 'glAlphaFunc' They're all from the file "gl.h", and even if I comment out #include <gl\gl.h> I still get them! Any idea why?

Share this post


Link to post
Share on other sites
Advertisement
Thanks! That fixed everything. One question, I already had <windows.h> in a file that was #included before the .h file with those was #included. Does it have to do with putting <windows.h> right before the openGL libraries?

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.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!