I’m trying to use the Stats module to track FPS performance while in VR. To do that, I need to make a mesh out of the Stats DOM element, as in the WebXR Sandbox example. However, the resulting mesh just looks black and doesn’t look like the DOM element, although I noticed that selecting it in the scene does target the DOM element. Below is the code I’m using to create the HTMLMesh, which follows the above example. Does anyone know how I can get the mesh to look like the DOM element in the scene?
stats = new Stats(); document.getElementById('container').appendChild(stats.dom); const interactiveGroup = new InteractiveGroup(renderer, camera); scene.add(interactiveGroup); const statsMesh = new HTMLMesh(stats.dom); statsMesh.position.y = 1; statsMesh.scale.setScalar(2); interactiveGroup.add(statsMesh);