'gluPerspective' was not declared in this scope gluPerspective

ゝ一世哀愁。 2023-05-31 06:51 39阅读 0赞

最近在Window10使用Qt5.12学习OpenGL时,出现了以OpenGL中glu开头的函数库无法使用的错误,例如:

‘gluPerspective’ was not declared in this scope

在引用了类似于gluPerspective函数的glu函数库所在源文件中添加头文件:#include

这一步必须,不知道为什么在QT5.2下使用OpenGL的以glu开头的GLu32库还需要包含gl/glu.h头文件,而使用OpenGL中以gl打头的OpenGL32库就不需要包含头文件了。

发表评论

表情:
评论列表 (有 0 条评论,39人围观)

还没有评论,来说两句吧...

相关阅读