if you have a secondary render target bound as in
glFramebufferRenderbufferEXT(GL_FRAMEBUFFER_EXT, GL_DEPTH_ATTACHMENT_EXT, GL_RENDERBUFFER_EXT, buffer);
should it respect the state of glDepthMask?
Our findings seem to indicate that it doesn’t, neither on NVidia nor AMD implementations (unless there was something wrong with our tests, which I can’t completely rule out).
If the answer is that depth is written regardless of glDepthMask state, is the recommended way to prevent such depth writing to temporarily unbind the depth render target?