[Csnd] web audio on node.js
| Date | 2025-11-12 23:17 |
| From | Victor Lazzarini <000010b17ddd988e-dmarc-request@LISTSERV.HEANET.IE> |
| Subject | [Csnd] web audio on node.js |
|
Has anyone tried this
I wonder if we could Csound on node.js with it.
Prof. Victor Lazzarini
Maynooth University
Ireland
|
| Date | 2025-11-13 11:31 |
| From | Lovre Bogdanić |
| Subject | Re: [Csnd] web audio on node.js |
Hi Victor!
I didn’t try that exactly but I did try something related that is maybe also interesting and that is Csound in Web Audio Modules (WAMs). If I’m not wrong, WAM is built on top of web audio api.
WAM api repo: https://github.com/webaudiomodules/api Here is an easy to follow example from Steven how to build WAM with csound: https://github.com/webaudiomodules/wam-examples/tree/master/packages/csoundPitchShifter And a nice tutorial also from Steven regarding Csound on Web: https://kunstmusik.github.io/icsc2022-csound-web/
I’ve developed a proof of concept for exporting a Cabbage 3 instrument as WAM: https://gitlab.gwdg.de/lovre.bogdanic/cabbage32wam. And also I developed a playground for WAMs in form of a browser based node editor called WANE: https://gitlab-pe.gwdg.de/lovre.bogdanic/wane and you can directly try it here: https://wane-3508d7.pages-pe.gwdguser.de/.
When it comes to cabbage32wam, its far from complete implementation but it works well for GUI to WebAudioNode communication (meaning changing gui widgets value propagates correctly to audio node) but other way around doesn’t work yet. Also currently only one instance of cabbage32wam can be loaded into WANE (bug in cabbage32wam).
If you (or anyone else ;) ) try it out, let me know what you think.
Hope this helps a bit.
Best, Lovre On Thu, Nov 13, 2025 at 12:17 AM Victor Lazzarini <000010b17ddd988e-dmarc-request@listserv.heanet.ie> wrote:
|
| Date | 2025-11-13 13:30 |
| From | Victor Lazzarini <000010b17ddd988e-dmarc-request@LISTSERV.HEANET.IE> |
| Subject | Re: [Csnd] [EXTERNAL] [Csnd] web audio on node.js |
Nice! Thanks for sharing. ======================== Prof. Victor Lazzarini Maynooth University Ireland > On 13 Nov 2025, at 11:31, Lovre Bogdanić |
| Date | 2025-11-13 16:21 |
| From | Steven Yi |
| Subject | Re: [Csnd] web audio on node.js |
Nice work Lovre! Regarding running on node.js, Hlodver originally did a @csound/node package that used the @csound/wasm-bin wasm binary, but that hasn't been kept up to date. There's also Nate Whetsell's csound-api package (https://www.npmjs.com/package/csound-api) that works with native csound. I think both paths (wasm vs native) would be great to have for Csound 7. On Thu, Nov 13, 2025 at 6:33 AM Lovre Bogdanić |