How can I read the depth buffer in WebGL?

前端 未结 5 1026
逝去的感伤
逝去的感伤 2021-01-05 08:01

Using the WebGL API, how can I get a value from the depth buffer, or in any other way determine 3D coordinates from screen coordinates (i.e. to find a location clicked on),

5条回答
  •  有刺的猬
    2021-01-05 08:39

    As of January 23, 2012, there is a draft WebGL extension to enable depth buffer reading, WEBGL_depth_texture. I have no information about its availability in implementations, but I do not expect it at this early date.

提交回复
热议问题