本文介绍了EGL_BAD_MATCH 与 Droid/Droid 2的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在各种手机上测试我的 OpenGL ES 2 应用程序.我在使用 Droid 和 Droid 2 时遇到了问题.我尝试的每个 EGL 配置都会导致 EGL_BAD_MATCH.

I've been testing my OpenGL ES 2 app on various phones. I've ran into a problem with the Droid and Droid 2. Every EGL config I try results in an EGL_BAD_MATCH.

我尝试了多种 EGL 配置组合,包括适用于其他手机的配置,每种组合都会产生 EGL_BAD_MATCH.

I've tried many combinations of EGL configurations, including configurations that work on other phones, and every combination results in an EGL_BAD_MATCH.

有没有人遇到过这个问题或知道任何解决方案?

Has anyone ran into this problem or know of any solutions?

谢谢

推荐答案

我在部分摩托罗拉和三星手机上也遇到了这个问题.问题是手机报告的像素格式与表面预期的不同.您需要为该手机设置适当的像素格式的表面视图,这很可能是 PixelFormat.RGB565

I also had this problem on select Motorola and Samsung handsets. The problem is the phone reports a different pixel format than the surface is expecting. You need to setup the surface view with the appropriate pixel format for that phone, which is most likely PixelFormat.RGB565

凯文

这篇关于EGL_BAD_MATCH 与 Droid/Droid 2的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-03 16:47