最近我得到了OpenGL SuperBible第5版.我很高兴开始阅读,当我进入第一部分关于如何正确设置所有内容时,我遇到了谷歌和其他StackOverflow问题都无法回答的问题.
我想明确表示我使用的是Visual Studio 2010并且所有内容都已正确链接.
我从官方的OpenGL Superbible网站下载了libs和header.
因此,当我编写第一个名为Triangle.cpp的程序并尝试编译它时,会出现以下错误.
1>------ Build started: Project: OpenGL, Configuration: Debug Win32 ------
1>Build started 7/19/2011 9:21:27 PM.
1>InitializeBuildStatus:
1> Touching "Debug\OpenGL.unsuccessfulbuild".
1>ClCompile:
1> Triangle.cpp
1>c:\sb5\src\gltools\include\glbatch.h(77): error C2061: syntax error : identifier 'GLenum'
1>c:\sb5\src\gltools\include\glbatch.h(86): error C2061: syntax error : identifier 'GLuint'
1>c:\sb5\src\gltools\include\glbatch.h(89): error C2061: syntax error : identifier 'GLfloat'
1>c:\sb5\src\gltools\include\glbatch.h(90): error C2061: syntax error : identifier 'GLfloat'
1>c:\sb5\src\gltools\include\glbatch.h(91): error C2061: syntax error : identifier 'GLfloat'
1>c:\sb5\src\gltools\include\glbatch.h(92): error C2061: syntax error : identifier 'GLfloat'
1>c:\sb5\src\gltools\include\glbatch.h(100): …Run Code Online (Sandbox Code Playgroud)