Live data from Hacker News

Show HN: a Rust ray tracer that runs on any GPU – even in the browser

github.com

1–10 of 30 posts

Show HN: a Rust ray tracer that runs on any GPU – even in the browser

#1
I’ve been experimenting with Rust lately and wanted a project that would help me explore some of its lower-level and performance-oriented features. Inspired by Sebastian Lague’s videos, I decided to implement my own ray tracer from scratch.

The initial goal was just to render a simple 3D scene in the browser at a reasonable frame rate. It evolved into a small renderer that can: • Run locally or on the web using wgpu and WebAssembly • Perform mesh rendering with a Bounding Volume Hierarchy (BVH) for acceleration • Simulate both direct and indirect illumination for photorealistic results • Be deployed easily as a free web demo using GitHub Pages

The project is far from perfect, but it’s been a fun way to dig deeper into graphics programming and learn more about Rust’s ecosystem. I’m also planning to experiment with Rust for some ML projects next.

GitHub: https://github.com/tchauffi/rust-rasterizer Web demo (desktop browsers): https://tchauffi.github.io/rust-rasterizer/

Would love feedback from anyone who’s built similar projects or has experience with wgpu or ray tracing in Rust.

Show HN: a Rust ray tracer that runs on any GPU – even in the browser
github.com

Re: Show HN: a Rust ray tracer that runs on any GPU – even in the browser

#4

It looks cool, nice project. Recommend taking a few minutes to make the web page work on mobile. For example on iPhone the actual webgpu/ray tracing seems to work fine but html formatting is shoving things over to be barely visible.

Thanks! It should work on mobile, you can hide the right panel using the button at the bottom of the screen. That said, performance on mobile is pretty limited because of hardware limitations.
Post reply on HN