I have an FBO with packed depth/stencil attachments (i.e. one renderbuffer with the packed format is attached to both) and would like to read the contents back to main memory. I’m thinking it should work something like this:
// create/setup FBO & buffers
// bind FBO
// render
glReadBuffer( ?? );
glReadPixels(0, 0, w, h,
GL_DEPTH_STENCIL_EXT,
GL_UNSIGNED_INT_24_8_EXT, pImg);
What is the value that needs to be passed to glReadBuffer? Thanks.