OpenGL ES problem with PowerVR SGX GPU

I have an OpenGL Live wallpaper that works fine on all phones except those with the PowerVR SGX series. This includes almost all Samsung phones and the Motorola Droid series. The wallpaper is nothing but a black screen on the PowerVR GPU phones. I have been racking my brain for a week trying to figure this problem out but have had no luck.

One difference between the different GPUs is their texture compression. Some of the things I have done in that regards is I have changed my texture image to a square of 256x256. Changed it from 8 bit to a 16 bit rgba and even tried indexed.

I have a list of all the extensions that are available with the PowerVR and the ones that are available with the Adreno. It seems that there are quite a few differences in available extensions but I do not know what functions go with what extensions (though I can somewhat guess). Here is a list of the functions that I use:

  • glLightfv
  • glMaterialfv
  • glDepthFunc
  • glEnableClientState
  • glViewport
  • glMatrixMode
  • glLoadIdentity
  • gluPerspective
  • glclearcolor
  • glclear
  • glTranslatef
  • glRotatef
  • glVertexPointer
  • glTexCoordPointer
  • glColor4f
  • glNormal3f
  • glDrawArrays
  • glTexParamterx
  • I am using Robert Green's GlWallPaperService and have tried this solution at Trying to draw textured triangles on device fails, but the emulator works. Why? . Does anybody have any idea why the PowerVR chips are giving me such a hard time and what I could do about it?


    Removing EGL10.EGL_RED_SIZE, EGL10.EGL_GREEN_SIZE, and EGL10.EGL_BLUE_SIZE but leaving EGL10.EGL_DEPTH_SIZE, EGL10.EGL_NONE in the eglChooseConfig worked. I assume that the PowerVR chip processes RGB in a way that makes defining them a problem.


    This probably won't help you, but I noticed:

    One difference between the different GPUs is their texture compression. Some of the things I have done in that regards is I have changed my texture image to a square of 256x256. Changed it from 8 bit to a 16 bit rgba and even tried indexed.

    To my knowledge, no current hardware supports indexed textures. Also, to use texture compression, you need to target a compressed texture format that is specifically supported by the device (which usually entails running a compressor on the host/development platform). SGX supports PVRTC and ETC but whether those are enabled depends on the platform


    From my own experience with this GPU, it will offer GLES configurations, that once applied will not work (ie the GLES context will not be created). The workaround is to look at the GLSurfaceView code, roll out your own and try out each offered configuration, whether it works for creating a context.

    链接地址: http://www.djcxy.com/p/33900.html

    上一篇: 我在opengles中获得纹理,现在我想旋转纹理,但失败了

    下一篇: PowerVR SGX GPU的OpenGL ES问题