what is wrong when i use Eglimage replace glreadpixels in NDK program?

后端 未结 1 674
迷失自我
迷失自我 2020-12-10 20:03
//step 2. Create the Android Graphic Buffer
GraphicBuffer* buffer = new GraphicBuffer(w, h,
   HAL_PIXEL_FORMAT_RGBA_8888,
   GraphicBuffer::USAGE_HW_TEXTURE |
   Gr         


        
相关标签:
1条回答
  • 2020-12-10 20:43

    You need a glFinish() call to tell the driver to do the actual drawing. The glReadPixels() call is causing things to work because it forces the rendering to happen -- you've told the driver that you want to read the pixels back, so it pauses until rendering is complete.

    0 讨论(0)
提交回复
热议问题