Implementing your own depth buffer with GLSL
I need a datastructure of the same size as the normal depth bu开发者_如何转开发ffer and I need to be able to read from and write to it in a shader. Is this possible, and what does this datastructure look like?
No, a GLSL shader cannot read and write the same buffer.
In a nutshell, parallelising the shader work would not be simple otherwise.
精彩评论