/wasm-ray

A Rust/WebAssembly implementation of Peter Shirley's "Ray Tracing in One Weekend" (which will take me longer than one weekend)

Primary LanguageRustApache License 2.0Apache-2.0

Ray tracing in Rust and WebAssembly

Cover Image

A live demo of the current code is available at https://aga3.xyz/wasm-ray

The wasm-based live demo lags far behind the native version due to performance limitations.

I pretty quickly ran into performance issues with the wasm version. I have not been able to successfully parallelize that version, and I'm not sure it's even possible. I may try to revisit it, or at least to enable it with some hard limits on resolution, etc. to make it run in reasonable time. It might not be that bad if I can also get a progress bar working or something...

This is a project to help me learn more about:

  • Ray tracing
  • Rust
  • WebAssembly (aka wasm)

Thanks to (very seriously in no particular order):