musescore / MuseScore

MuseScore is an open source and free music notation software. For support, contribution, bug reports, visit MuseScore.org. Fork and make pull requests!
https://musescore.org
Other
12.13k stars 2.63k forks source link

[MU4 Issue] Playback is laggy and has popping noises when compared to MU3 due to buffer size (Windows) #11222

Closed GabeS573 closed 1 year ago

GabeS573 commented 2 years ago

Describe the bug The playback sound in MuseScore 4 is more jittery/laggy/disconnected sounding than it was in MU3. Also, popping noises can be heard.

To Reproduce Steps to reproduce the behavior:

  1. Find a score with many instruments (I used https://musescore.com/pukalo/scores/1506861 in the recording below, but the issue happens with any score and is especially noticeable with percussion ensemble music.)
  2. Make two copies of the score. Open one copy in MU3 and the other copy in MU4.
  3. Play the MU3 version, then the MU4 version
  4. Compare how they sound.

Recording (MU3 first, then MU4): (video is sound only)

https://user-images.githubusercontent.com/91428485/163731096-374638d3-ee7b-4634-a083-cfac81ca2739.mp4

Expected behavior The playback should be similar to MU3 without jittering, popping noises and a laggy feeling.

Screenshots N/A

Platform information

Additional context I have not edited any sound-related preferences in MU3 or MU4.

mattblo commented 2 years ago

This problem bothers me every time I open a file from Musescore 3! Always this popping noise in between...

Rchatru commented 2 years ago

I have exactly the same problem. It happens both with imported files from the previous Musescore 3, and with the files created with this one.

If you need more information or to do some tests, I'm available to help in any way I can.

JezSonic commented 2 years ago

well.. same problem here. I hope someone will fix that

mattblo commented 2 years ago

Shouldn't this be assigned to the Alpha2 as it affects the default playback? I have this problem on 2 out of 3 notebooks I have tested Musescore4 on.

mattblo commented 2 years ago

In the latest NightlyBuild, the audio buffer can be set. If I set the highest possible value there (4096), the annoying crackling is over. With 2048 unfortunately not yet. The question is whether there should not be a higher buffer value for older hardware, since my notebook is fairly new and has an i7, which should definitely not be too weak for Musescore.

mattblo commented 2 years ago

Perhaps the default buffer value should also be set much higher, since many users probably don't want to search through the settings to get the sound to sound good.

wizofaus commented 2 years ago

Can confirm that setting the buffer size to 4096 fixes this problem for me. Any disadvantage in a higher buffer size @vpereverzev ?

Rchatru commented 2 years ago

I also had the same problem. As already mentioned, it helped me to change the buffer size setting from 1024 to 2048, as you can see in the audio. I hope it can help someone, because I found the solution by chance.

Buffer

https://user-images.githubusercontent.com/38190230/188969480-bb595d52-f8bc-452d-bd67-9d860155e716.mp4

https://user-images.githubusercontent.com/38190230/188969476-953ec949-69d8-43a8-9dcb-6dc44961aece.mp4

vpereverzev commented 2 years ago

@GabeS573 @wizofaus @mattblo @Rchatru @JezSonic is everybody having these problems specifically on Windows?

cbjeukendrup commented 2 years ago

If I set the buffer size very low (32), it seems I can also reproduce it on macOS. But I do notice that I need a much higher buffer size on Windows than on macOS; on Mac, even 128 already seems to work reasonably (for small scores).

wizofaus commented 2 years ago

Windows for me, yes, but it's fine with 4k buffer size.

GabeS573 commented 2 years ago

I still experience it on Win11, but I'm not able to test any other operating systems. The sound is mostly fine on the largest buffer size.

Rchatru commented 2 years ago

Correct, it happens to me in Windows 10

cbjeukendrup commented 2 years ago

By the way, here is an issue that seems related: #12637 (just linking it so that we don't forget to re-check one if the other gets fixed)

mattblo commented 2 years ago

I also use WIndows 11, but in the latest NightlyBuilds I no longer have this problem. Even with a buffer of 256, the playback is fine!

wizofaus commented 2 years ago

Just tried latest build (from source, debug build) on Windows 10 and playback is now fine at 1024 buffer size, but not 512 or 256 (256 is esp. weird, seems to repeat lots of notes). But what's the advantage in using a buffer size below 1024?

wizofaus commented 2 years ago

Sorry I take that back, it's still not good even at 1024 (it was ok for about 30 seconds but after that started distorting/skipping etc.) 2048 seems fine.

Tantacrul commented 1 year ago

Closing this as a duplication of https://github.com/musescore/MuseScore/issues/12483