Tone.Draw↳ EXTENDS Tone
Tone.Draw is useful for synchronizing visuals and audio events. Callbacks from Tone.Transport or any of the Tone.Event classes always happen before the scheduled time and are not synchronized to the animation frame so they are not good for triggering tightly synchronized visuals and sound. Tone.Draw makes it easy to schedule callbacks using the AudioContext time and uses requestAnimationFrame.
CONSTRUCTORnew Tone.Draw ( )
.anticipation↝ Number #
The amount of time before the scheduled time that the callback can be invoked. Default is half the time of an animation frame (0.008 seconds).
.cancel ( )#
Time after which scheduled events will be removed from the scheduling timeline.
Cancel events scheduled after the given time