OpenGL ES 2.0 中的浮点纹理 [英] Floating Point Textures in OpenGL ES 2.0

查看:39
本文介绍了OpenGL ES 2.0 中的浮点纹理的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直试图弄清楚如何在 GLES2 中使用浮动纹理.API 参考 说只有无符号字节和短裤可以使用过,但我看到有人说它在其他地方受支持.

I've been trying to figure out how to use float textures in GLES2. The API Reference says that only unsigned bytes and shorts can be used, but I've seen people saying it is supported elsewhere.

我可以使用 GL_LUMINANCE 作为纹理格式,但这只能得到一个浮点值.

I could use GL_LUMINANCE as the texture format but that only gets me one float value.

推荐答案

在 OpenGL ES 2.0 中,仅当实现导出 OES_texture_float 扩展.请注意,此扩展仅允许在纹理级别内进行最近过滤,而不允许在纹理级别之间进行过滤.OES_texture_float_linear.另一个潜在的警告是 OES_texture_float 的存在并不要求实现支持渲染到带有帧缓冲区对象的浮点纹理.

In OpenGL ES 2.0, floating-point textures are only supported if the implementation exports the OES_texture_float extension. Note that this extension only allows nearest filtering within a texture level, and no filtering between texture levels. This restriction is loosened by the presence of OES_texture_float_linear. Another potential caveat is that the presence of OES_texture_float does not require that the implementation support rendering to floating-point textures with framebuffer objects.

你想用浮动纹理做什么?

What are you trying to do with float textures?

这篇关于OpenGL ES 2.0 中的浮点纹理的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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