嗨,这是我提到问题以来的第三次renderer.domElement remove from document body then its delete but I want to delete the renderer.domElement child delete which is not delete .Here is the code which I'm using in my project.请检查三
。
Hi its my third time since I have mentioned my question but I didn't get the proper solution .The problem is I create div in runtime but after once I click the div then function call and click but div is not remove event if I remove renderer.domElement remove from document body then its delete but I want to delete the renderer.domElement child delete which is not delete .Here is the code which I'm using in my project. Please check if three.js admins or members read this question then please don't ignore it I will be very thankful for help :)
JSFiddle: [https://jsfiddle.net/regeme786/vmx8uLd1/22/]
发布评论
评论(1)
如果要从CSS渲染器中删除元素,则必须删除其实例
css2dobject
。不是元素本身。因此,而不是这样做:您必须使用
three.js
api:If you want to remove an element from the CSS renderer, you have to remove it's instance of
CSS2DObject
. Not the element itself. So instead of doing:you have to use the
three.js
API: