WhitmanCS370 / Frends-Audio-Archive

0 stars 4 forks source link

When playing in parallel, both sounds last only as long as the shortest sound. #78

Closed Rhys-sg closed 6 months ago

Rhys-sg commented 7 months ago

To recreate:

  1. python src/cli.py add ./sounds/toaster.wav
  2. python src/cli.py add ./sounds/coffee.wav
  3. python src/cli.py play toaster coffee -p

toaster.wav is longer than coffee.wav, but only lasts as long as coffee.wav

Rhys-sg commented 7 months ago

This implementation does not work, but it might be a start:

while any([play_obj.is_playing() for play_obj in play_objs]): pass

for play_obj in play_objs: play_obj.stop_all()

LeedsJohn commented 6 months ago

@Rhys-sg Interesting, I wasn't able to replicate this. Did someone fix it? Or I wonder if works on unix but not windows?