我正在为我的下一款 Android 游戏编写一个支持 OpenGL ES 的框架.目前我支持三种不同的精灵绘制技术:
I'm in the process of writing an OpenGL ES powered framework for my next Android game(s). Currently I'm supporting three different techniques of drawing sprites:
OpenGL ES 1.0 支持顶点数组,因此每个 Android 设备都支持.我猜大多数(如果不是全部)当前设备也支持 VBO 和 draw_texture.
Vertex arrays are supported in OpenGL ES 1.0 and thus in every Android-device. I'm guessing most (if not all) of the current devices also support VBOs and draw_texture.
我想知道不同设备支持的扩展,而不是猜测.如果大多数设备都支持 VBO,我可以简化代码并只关注 VBO + draw_texture.
Instead of guessing, I'd like to know the extensions supported by different devices. If majority of devices support VBOs, I could simplify my code and focus only on VBOs + draw_texture.
了解不同的设备支持什么会很有帮助,因此如果您有 Android 设备,请报告扩展程序列表.:)
It'd be helpful to know what different devices support, so if you have an Android-device, do report the extensions list please. :)
String extensions = gl.glGetString(GL10.GL_EXTENSIONS);
我有一个 HTC Hero,所以接下来我可以分享这些扩展.
I've got a HTC Hero, so I can share those extensions next.
HTC G1 (Android 1.6) 上的 OpenGL ES 扩展:
OpenGL ES extensions on HTC G1 (Android 1.6):
HTC G1 (Android 1.6) 上的 OpenGL ES 版本:
OpenGL ES version on HTC G1 (Android 1.6):
我将包含以下人检索到的版本:gl.glGetString(GL10.GL_VERSION)
I'm including the version as retrieved by:
gl.glGetString(GL10.GL_VERSION)
这很有趣,因为它不遵循规范.配置文件应该在数字之前.还需要确定能力.例如,Droid 不会在其扩展列表中报告 VBO 支持.但是,它确实报告了 1.1 的 OpenGL ES 版本.这意味着它确实支持 VBO,因为 VBO 在 1.1 版本中是强制性的.
It's pretty interesting in that it doesn't follow the specification. The profile is supposed to be before the number. It is also needed to determine capabilities. For example, the Droid doesn't report VBO support in its extension list. It does report an OpenGL ES version of 1.1, however. That means it does support VBOs, because VBOs were made mandatory in the 1.1 version.
这篇关于OpenGL 扩展可用于不同的 Android 设备的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!