Back to Blog
Vec2 Pack5/28/2023 ![]() ![]() ![]() Note that in my code, near is 0.0 and far is 1.0, which are the default values of glDepthRange. I have been trying to figure out whats wrong by observing the bits, results at the bottom. The shader, that is used only for depth rendering, should write glFragCoord.z value (the distance value that we want to read.) on the glFragColor. Unfortunately OpenGL ES only supports GLALPHA, GLRGB, and GLRGBA as the readback formats, so theres really no way to reach the framebuffers depth data directly.
0 Comments
Read More
Leave a Reply. |