ya i'm sure that i'm calling afterPresentRenderbuffer for the framebuffer that i have defined in createframebuffer.As multiple render pass requires binding 2 or more framebuffers for a single pass.
consider that fbo1(framebuffer object) is used for everyplay and fb02 is for shadows, then comes the order of execution per frame without shadows
while(1){
glClearColor(0.45f, 0.45f, 0.45f, 1.0f);
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
....
glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
...
[(EAGLView *)self.view presentFramebuffer];
}
below code order is for rendering with shadows
while(1) {
glClearColor(0.45f, 0.45f, 0.45f, 1.0f);
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
renderShadow();
glBindFramebuffer(GL_FRAMEBUFFER, fbo1);
....
glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
...
[(EAGLView *)self.view presentFramebuffer];
}
renderShadow(){
glBindFramebuffer(GL_FRAMEBUFFER, fbo2);
....
glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
....
}
when i shift the glBindframebuffer with two FBo's , the screen becomes blank and everyplay records the blank screen.
If i remove Everyplay's integration the above code for shadows works well.
In the example project provided by Everyplay for ios "EveryplayRecord.xcodeproject", if i include the line
glBindFramebuffer(GL_FRAMEBUFFER, defaultFrameBuffer); // in drawRect() method it also renders blank screen.