Threejs scene inside a pane/window

Can you insert a threejs scene inside a container?

It doesn't allow me to do an addTo().

Thanks

No - it is an overlay. I think it is a Tag() or a createjs DOMElement. So maybe it can be positioned at a Container and scaled and moved with the Container but it will not really be in it.

That's right. I will give it a go. Thanks

I have threejs inside of ZIM and want to keep it that way and add a "container" onto the sides of a cube.

I know about textureActives and have been playing with them to add canvas content onto a cube but textureActive automatically takes that whole scene into a threejs scene, entire screen is 3d, and the texture active content doesn't get added to the cube.

Is it possible to add use texttureactive without having the whole scene go into 3D? I want to contain it inside a ZIM canvas.

If you make a TextureActive you have to make sure to add it to a TextureActives (plural) object and then map the textureActive.canvas CanvasTexture onto the cube material. If you do not pass the TextureActive to the TextureActives obj then it may appear as a ZIM FIT mode on the whole page.

When you used TextureActive with three.js it is really a three.js canvas you are making. This is usually full screen but does not have to be. You can can show three.js in a div for instance in your HTML page - scale and position it with CSS, etc.

I have not tried adding a three.js scene with a TextureActive back into ZIM as a three.js "inside" ZIM format. I think it would work but not sure. It would be TWO ZIM Frames each with a new Three() objects - one with textureActive:true and then a second later without that.

If you have not already, please see the  ZIM with three.js  page and note the videos that talk about the different ways to use ZIM and three.js together.