Android 上符合 OpenGL-ES 2.0 所需的最小纹理大小?
某个硬件是否需要支持最小纹理尺寸才能符合 OpenGL-ES 2.0 规范?
GL_MAX_TEXTURE_SIZE 值必须至少为 1024 或 2048 或类似的值?
我想知道这一点的原因是因为我正在研究使用着色器的东西,因此必须是 OpenGL-ES 2.0。因此,我想让纹理尽可能大,而不必考虑每个硬件纹理限制(例如只有 512x512 的旧手机)。
如果有一个最小数量(或大多数设备支持的某个值),那将对我有很大帮助。
is there a minimum texture size a certain hardware needs to support to be compliant with the OpenGL-ES 2.0 specification ?
Something like the GL_MAX_TEXTURE_SIZE value has to be at least 1024 or 2048 or something like that ?
The reason I would like to know this is because I work on something that uses shaders and as such has to be OpenGL-ES 2.0. Therefore I would like to make the textures as big as possible without having to consider each and every hardware texture limitation (like the old phones with only 512x512).
If there was a minimum number (or a certain value that most devices support) that would help me alot.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
是的,任何 GLES2 实现都必须支持宽度和高度至少为 64 像素的纹理。
您可以使用 GL_MAX_TEXTURE_SIZE 枚举通过 glGetIntegerv 函数查询实际的最大纹理大小。
请参阅官方规格第 141 页,表 6.20。
Yes, any GLES2 implementation must support at least 64 pixel texture in width and height.
You can query actual actual max texture size with glGetIntegerv function using GL_MAX_TEXTURE_SIZE enum.
See official spec page 141, table 6.20.