-
Notifications
You must be signed in to change notification settings - Fork 27
Description
Hello,
I am in the process of migrating from pure threejs + angular app to using this threejs abstraction layer for angular and this is awesome so far.
We currently have 2 major headaches tough:
First one is to be able to introduce HTML directly inside 3D components. Our goal, which we were achieving before migration, is to be able to put (mostly) texts element alongside a mesh. We had all the mechanics of finding the absolute position where it should be displayed according to camera and mesh position. Doing it now with ngx-three would just be a very breeze to use once implemented. The problem is it seems that any template html produced inside a ThCanvas is evaporating so we cannot have our labels displayed.
We are currently passing template refs to a service which then spits it on screen and synchronizes with the view to position them. An example use this feature would be the Html component from @react-three/drei
The second problem is for Picture-In-Picture and is dependent on one. We had made a mecanic to be able to use only one rendering context/canvas to display different scenes or views. ngx-three works very nicely with multiple views and we expect we could make a component leverage this plus the ability to add HTML to create PIP inside html elements using a second canvas where a part of the "main" is copied to.
Anyways, just to be sure, I am not requesting that those features be added in the core of the module as I clearly understand that its goal is to simply wrap threejs into angular components. But we are a bit out of ideas on how to use this great package while be able to expend onto it.
Would you be aware of techniques that we could use to get to our goals without any changes to the package source?
If not, would you consider a PR that allowed for template html's to "bubble up" from the canvas?