Investigate implementation of https://developer.mozilla.org/en-US/docs/Web/API/OffscreenCanvas. This would give us:
- possible additional performance for the application, as playcanvas part of the application including webgl would execute on separate thread
- ability to use Atomics library https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics on both webgl and worker threads, allowing us to write a job system which can execute jobs triggered on webgl thread and get results back inside the same frame, without using messages for synchronization.
Investigate implementation of https://developer.mozilla.org/en-US/docs/Web/API/OffscreenCanvas. This would give us: