Skip to content

Latest commit

 

History

History
19 lines (15 loc) · 1.07 KB

README.md

File metadata and controls

19 lines (15 loc) · 1.07 KB

Wasm Opus Transcoder

This library transcodes audio files to OGG Opus in the browser using WASM. It also provides some other WASM-compatible utilities for hashing bytes and converting embedded cover arts.

Encoding to Opus uses unsafe-libopus and this patch (actually my fork) for opus-rs. Then we glue that together with Symphonia for audio decoding, Rubato for resampling, and ogg. You can see this in transcoder/.

transcoder-wasm/ is a simple wrapper that provides JS bindings which gets compiled with wasm-pack.

There's a Svelte demo in transcoder-demo/. The transcoding is done in a web worker that comunicates with the UI to prevent it from blocking the page while it's working. You can try it online here.