[Csnd] CMask ported to WebAssembly as part of csound-extended

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[Csnd] CMask ported to WebAssembly as part of csound-extended

Michael Gogins-2
I have, after successfully asking the author to change the license of
CMask to one compatible with csound-extended, ported Andre Bartetzki's
CMask program to WebAssembly and it now is part of the WebAssembly
build of csound-extended.

A live demo can be viewed at
https://gogins.github.io/csound-extended/cmask.html.

This little project has been instructive for me. First, I found it is
fairly easy to port existing C/C++ algorithmic code to WebAssembly and
it incorporate the results into csound-extended. Second, just as
expected, anything with a JavaScript interface will work with anything
else with a JavaScript interface. Third, currently the integration of
multiple WebAssembly modules in one Web page is not possible without
some hacking.

In this case, I simply built CMask as a WebAssembly library and linked
it into the csound-extended module. In other cases, it is possible to
load different WebAssembly modules in different function scopes (you
can't do that simply by using a different <script> element for each
WebAssembly module).

In the future, it should be possible to simply use any WebAssembly
module as an ECMAScript module, and this problem should go away.

Regards,
Mike

-----------------------------------------------------
Michael Gogins
Irreducible Productions
http://michaelgogins.tumblr.com
Michael dot Gogins at gmail dot com

Csound mailing list
[hidden email]
https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
Send bugs reports to
        https://github.com/csound/csound/issues
Discussions of bugs and features can be posted here