I would try to run the surface reconstruction in a worker to see how it behave assuming you can implement it in JS or WASM.