Closed cantonbecker closed 3 years ago
Please post questions to the forums and not the issues page.
My guess by glancing at your snippets: the timing issue is related to not using the transport time in the callback function. Make sure you pass the time
given by Transport.schedule
in when scheduling your samples.
I wonder if anyone has advice on how to make my Tone.js composition a little more reliable:
https://pisongs.com/techno/
After the samples load and the play button is revealed, click the play button. After a few seconds -- when the digit "1" lights up in the "3.14" tickertape) you should hear a bell rhythm and a banging beat, generated by:
The way I've solved this in the past is by detecting the browser and adding extra silence at the beginning of the whole song, sometimes up to 6 seconds. But I wonder if there's something fundamentally wrong about how I'm invoking the Tone.js audio engine or something.
If you view source on the page, 100% of the javascript is right there in the html file. Nothing is external other than Tone.js, which makes it pretty easy to examine/debug.
Thanks for any tips!