[Media] WebGPU × WebAssembly rendering and computing engine for scientific workloads in the browser

84 points zushah 27 comments
[Media] WebGPU × WebAssembly rendering and computing engine for scientific workloads in the browser

I built WasmGPU, which is a WebGPU × WebAssembly rendering and computing engine for scientific workloads in the browser.

The WebAssembly section of the "double-brain" architecture is implemented in Rust and it handles the engine's hot paths: data-oriented transform storage and propagation, animation and glTF asset processing, bounds computation and frustum culling, ndarray indexing and zero-copy data staging for JavaScript interoperability, and low-allocation runtime infrastructure tuned with Binaryen and SIMD128.

I attached an image of the galaxy example. On my RTX 4060, it runs with 250,000 points runs at around 450fps, and a quick stress test at 8,388,608 points (hitting the 128 MiB storage buffer binding size limit) runs at around 45fps.

Repo: https://www.github.com/Zushah/WasmGPU
Website: https://zushah.github.io/WasmGPU
Example: https://zushah.github.io/WasmGPU/examples/galaxy.html

I'd love to hear any thoughts or feedback.