drawing a texture quad to a native display (glTexSubImage+glDrawArrays+eglSwapBuffers)
to
Drawing a pixel buffer directly to the framebuffer without using any opengles
there was a VERY noticable difference. The direct draw to framebuffer was 3 times faster. Is there any way to tweak and optimize (1). What could be the cause of delay? Does a texture upload involve some inter process communication?
How do you measure the time? What size is the rectangle you’re copying to the screen?
It’s extremely unlikely that the first method would be faster than the second, since it involves at least two copies: glTexSubImage copies from application memory to texture memory, and the renderer reads from texture memory and writes to the frame buffer.
In addition, texture upload is not just a straight copy. The texture data gets reformatted to optimize memory access patterns.