c++ - Reading depth buffer in Android native code, using OpenGL ES 3.0 -


i'm creating application render image offscreen , need read depth buffer. pc version of application easy, since can use glgetteximage or glreadpixels (using gl_depth_component). need port application android, have issues, since gl es not support glgetteximage @ all, , glreadpixel can used read color buffer (as understood).

many people suggest render depth buffer color buffer (or render depth value color buffer), understand, glreadpixel can read 8 bit per channel values, , need @ least 16 bit per depth values.

my target android device supporting opengl es, reading pixel buffer object, seams pbos faster method of transferring data gpu, read depth map still need use glreadpixels transfer depth map pbo (which not possible).

i thinking maybe creating eglimage (wrappening own buffer) , use depth texture in fbo might solution, don't have experience eglimages, i'm not sure if possible or not (and work on android, need have different implementations pc , android).

so, best solution access depth map using opengl es 3.0?


Comments

Popular posts from this blog

javascript - how to protect a flash video from refresh? -

android - Associate same looper with different threads -

visual studio 2010 - Connect to informix database windows form application -