CSS3DObject is Always in Front of WebGL Mesh

旧街凉风 提交于 2019-12-22 21:45:38

问题


I am mixing the CSS3D Renderer with WebGL Renderer to add HTML elements in 3D space to a WebGL scene. The CSS3DObject is in front of WebGL Meshes even though the WebGL Renderer has a higher z-index.

Here is the jsfiddle http://jsfiddle.net/kd9Tc/

This is what the scene looks like. Note the back view.

Whenever the CSS3DObject hits a mesh, I would like the correct depth to be displayed. I believe that this has something to do with the z-buffer or depth. I would prefer to have the text on a transparent background and not a solid color as shown in the example.

How can this be done?

来源:https://stackoverflow.com/questions/21171606/css3dobject-is-always-in-front-of-webgl-mesh

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!