Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
FM Synthesizer in the Browser via Rust and WebAssembly SIMD (ameo.design)
1 point by Ameo on June 25, 2021 | hide | past | favorite | 1 comment


Thanks to the recent stabilization of WebAssembly SIMD, this should run at full speed in Firefox and Chrome!

The audio is generated from scratch as samples (floating-point numbers from -1 to 1) by the WebAssembly code running on your browser's audio rendering thread; all DSP logic there is custom, and it is SIMD-accelerated for high performance even on mobile devices.

Some other features like the filter are implemented using the browser's built-in Web Audio API. Visualizations are made using WebGL with a library called PIXI.JS, and the core of the application is just a plain React app.

I have a blog post where I go into much more detail about its inner workings: https://cprimozic.net/blog/fm-synth-rust-wasm-simd/

Give it a try! Test out a few presets to see the range of sounds it can produce.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: