Is it possible to combine CSS2DRenderer and DAT.GUI together when the gui overlays the scene?

Hi,

I have a scene with some GUI (dat.gui) that are superimposed on the scene
I am able to add labels on 3D objects with CSS2DObject and CSS2DRenderer but then the controls
are not responding anymore.

If I reduce the size of the renderer or the size of the labelRenderer to make the controls not overlay the scene, everything works fine.

Unfortunately, I lose a lot of space because I have a lot of controls.

Is it possible to make that work or I have to use other methods to add labels?

Thanks !!

1 Like

Have you tried to modify the dat.gui container with CSS so it is always positioned on top? Something like:

.dg.ac {
    z-index: 1000 !important;
}
1 Like

nope… and actually that was the solution!
thanks!

1 Like