Have you considered rendering the WebGL scene to an Offscreen Canvas in a Web Worker? You lose the ability to process PointerEvents (since Web Workers can't access the DOM), but you can serialize PointerEvent data and send it to the Web Worker via postMessage. That does introduce a bit of latency (~0.5 ms) that might cause some jank since PointerEvents are emitted ~8ms. It's something I'm playing around with.
Wasn’t aware of FreeFlyer yet, most extensive set of visualisations I have seen so far. Some of these I was dreaming about already implementing cool bit scary to see a team who has done so already :)
I am using multiple webworkers for data handling aspects and orbit propagation. haven’t looked into rendering the webgl scene in a webworker yet, what would you say the main advantage is?
Have you considered rendering the WebGL scene to an Offscreen Canvas in a Web Worker? You lose the ability to process PointerEvents (since Web Workers can't access the DOM), but you can serialize PointerEvent data and send it to the Web Worker via postMessage. That does introduce a bit of latency (~0.5 ms) that might cause some jank since PointerEvents are emitted ~8ms. It's something I'm playing around with.
Neat project though! Stick with it! If you're looking for some ideas/inspiration, check out FreeFlyer: https://www.youtube.com/watch?v=Cwau4GrxuUU