ryohey / signal

Online MIDI Editor: signal
https://signal.vercel.app
MIT License
1.2k stars 136 forks source link

MIDI playback breaks when alt-tabbing on Chrome #373

Open spessasus opened 3 weeks ago

spessasus commented 3 weeks ago

Describe the bug When using a MIDI output to play back a file, the playback stutters and skips when alt-tabbing to a different window. The events are all executed at once in around 1 second intervals. Firefox is unaffected Video: https://github.com/ryohey/signal/assets/95608008/b1a04e6c-8684-4c21-b1e6-081c6d7e2d13

To Reproduce Steps to reproduce the behavior:

  1. Open signal, select a MIDI output instead of Signal Factory Sound. (SpessaSynth is the synthesizer in my example)
  2. Upload a MIDI file
  3. Play it normally
  4. Alt-tab to a different window (Firefox in my example)
  5. Hear playback stutter. (I have confirmed that this is not a bug with SpessaSynth, it happens with other synthesizers such as fluidsynth too)

Expected behavior The file should play back normally.

Screenshots See video.

Desktop (please complete the following information):

Smartphone (please complete the following information): N/A

Additional context N/A