Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,13 @@ export class AlphaSynthAudioWorkletOutput extends AlphaSynthWebAudioOutputBase {
public override play(): void {
super.play();
const ctx = this.context!;

// clear any pending events buffered from previous playback rounds
// we just want the events which come in after the play call until the worklet is created
if (this._pendingEvents) {
this._pendingEvents = undefined;
}

// create a script processor node which will replace the silence with the generated audio
BrowserUiFacade.createAlphaSynthAudioWorklet(ctx, this._settings).then(
() => {
Expand Down
Loading