显示 HUD 显示的 OpenGL ES 在纹理 3D 对象顶部没有颜色

发布于 2024-08-29 19:57:28 字数 681 浏览 1 评论 0原文

我是 iPhone 操作系统开发的初学者。

我在这里遵循了 jeff 的关于 iphone OS 中的 hud 显示的教程 http://iphonedevelopment.blogspot.com/ 2010/02/drawing-hud-display-in-opengl-es.html 该示例适用于附带项目,以等面体作为 HUD 的背景,并且颜色和文本按预期工作。

但是,当我将代码复制到修改后的项目中时,其中包含他的教程系列之一中的纹理对象http://iphonedevelopment.blogspot.com/2009/05/opengl-es-from-ground-up-part-6_25.html,我无论我如何更改颜色设置,HUD 显示都没有颜色。

我尝试禁用和启用客户端状态和 GL 模式,但没有成功。 任何分析过情况、经历过这种情况、找出代码需要更改的地方的人,请告诉我

Im a beginner on iphone OS development.

I followed jeff's tutorial here about hud display in iphone OS
http://iphonedevelopment.blogspot.com/2010/02/drawing-hud-display-in-opengl-es.html
The sample works on the accompanying project with the isocahedron as the background of the HUD and the is working as expected with colors and the text.

But when I copied the code into my modified project with the textured objects from one of his tutorial series on this one http://iphonedevelopment.blogspot.com/2009/05/opengl-es-from-ground-up-part-6_25.html, I see that the HUD display has no colors no matter how I change the color settings.

I trial and error of disabling and enabling the client states and the GL Modes with no luck.
Anyone who had analyzed the situation, has experienced such, has find out what's needed to change in the code, please let me know

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

烟燃烟灭 2024-09-05 19:57:28

在绘制 HUD 之前,请检查是否禁用了 GL_LIGHTINGGL_TEXTURE_2D

Check that you disable GL_LIGHTING and GL_TEXTURE_2D before you draw the HUD.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文