GL_MULTISAMPLE在哪里定义? [英] where is GL_MULTISAMPLE defined?

查看:1972
本文介绍了GL_MULTISAMPLE在哪里定义?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

虽然我不喜欢阅读OpenGL红皮书,但我仍在这样做,因为它是为初学者设计的唯一的图书,教程和/或文档不能完全替代书虽然很重要。

Although I have been discouraged from reading the OpenGL redbook, I am still doing it, because it is the only book designed for beginners, and tutorials and/or documentation don't quite substitute for a book although very important. So much for justifying myself :)

现在,有一个使用multisampling的抗锯齿的例子,涉及
glEnable(GL_MULTISAMPLE);

Now, there's an example for antialiasing using multisampling, which involved glEnable(GL_MULTISAMPLE);

我使用Qt,我得到一个编译错误,因为GL_MULTISAMPLE是一个未声明的标识符。我目前看到以下原因:

I am using Qt, and I get a compile error, because GL_MULTISAMPLE is an undeclared identifier. I currently see the following reasons:


  • 对于某些实现,包括Qt中的一个,GL_MULTISAMPLE没有定义。
  • 不在GL / gl.h或GL / glu.h中,而是在< QGLWidget> 中不包含的其他标题中。

  • For some implementations, including the one that comes with Qt, GL_MULTISAMPLE is not defined.
  • It is not in GL/gl.h or GL/glu.h but rather in some other header which is not included in <QGLWidget> or does not come with Qt
  • It is obsolete/deprecated

是上述之一原因正确吗?如果没有,这是我没有它的原因,我如何获得?提前感谢

Is one of the above reasons correct? If not, which is the reason I don't have it and how can I obtain? Thanks in advance

推荐答案

GL_MULTISAMPLE >用于扩展到OpenGL,直到1.3,并且是否实现取决于您的硬件/驱动程序/供应商实现。您可能实际想改用 GL_MULTISAMPLE_ARB

另请参阅:

  • http://www.opengl.org/resources/faq/technical/extensions.htm
  • http://www.gamedev.net/community/forums/topic.asp?topic_id=536666

RA的响应将简化扩展处理 - 我更喜欢使用 GLee 自己,但是他们是可以互换的(和GLee的惰性初始化,帮助我解决一个关键问题在Solaris),但GLEW保持更新的(GLee已经过时,它给我的注意。)。

RA's response will simplify extension handling - I prefer the use of GLee myself, but they are pretty much interchangeable (and GLee does lazy init which helped me fix a critical issue on Solaris), but GLEW is kept more up to date (GLee is outdated now that Kos has brought it to my attention.).

这篇关于GL_MULTISAMPLE在哪里定义?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆