jpcy / xatlas

Mesh parameterization / UV unwrapping library
MIT License
2.02k stars 216 forks source link

co_await support #111

Open unicomp21 opened 1 year ago

unicomp21 commented 1 year ago

Given co_await will soon be available in webassembly, would it make sense to add co_await support to xatlas? The intention would be to have xatlas suspend after every x cpu cycles. This would allow yielding to the main javascript thread (event loop) while in the middle of a large xatlas computation/job, and then be resume later via a microtask on the javascript side. Having this level of cooperative yielding would allow xatlas work to be visualized in real-time on the webgl side? Making for a better user experience? When using xatlas.js