Closed phal0r closed 6 years ago
Thank you for raising this issue. I would definitely appreciate your help with refactoring. A pull request would be ideal.
Ok, sure thing. I already forked it and added ArrayBuffers and AudioBuffers as valid source porperty for WAD :)
Those sound like useful features. Just be careful not to break any recording features, since I believe creating a Wad from a recording also uses ArrayBuffers. Check out lines 2594-2599 3298-3311 in build/wad.js. There might be an opportunity for a refactor there as well.
Thanks for the hint, I will check it out.
I just ran into this issue as well. I am using Wad in my react app that uses pure ES6 with Babel. if I try and use tuna I get the following error: TypeError: Wad.tuna is undefined ["./node_modules/web-audio-daw/build/wad.js"]/</Wad</setUpTunaOnPlay
Looking forward to this fix! Thanks,
Tuna should now work properly in version 3.0.0.
When using Common.js to load WAD, Tuna is included in the build, but also recognizes the presence of module.exports and is not exposed to the window object. While this behaviour is correct, WAD hardcodedly tries to access Tuna via window object:
As a workaround I am using this:
I suggest refactoring to a Common.js build which uses tunjas as dependency from NPM, so the min build will include it automatically and Common.js environments will treat Tuna as normal dependency. If you want, I can help you in this matter.