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.3k stars 2.66k forks source link

[MU4 Issue] All instruments are out of tune and the sound output is broken, when an 8-channel audio output device is selected. #19286

Closed MineCake147E closed 1 year ago

MineCake147E commented 1 year ago

Issue type

General playback bug

Bug description

When I configured VoiceMeeter Aux Input(VB-Audio VoiceMeeter AUX VAIO) to 8ch, the Muse Sound Grand Piano produces the A4 note at 1780Hz, about 4 times higher than it supposed to be. Changing the instrument to SoundFonts like MS Basic Grand Piano makes it even worse due to https://github.com/musescore/MuseScore/issues/15615, which is now fixed by https://github.com/musescore/MuseScore/pull/16018. VSTs like Dexed are also affected. The waveform of the output sound appears to be a chunk of 2048 samples (twice the buffer size set in the preferences) repeated up to 8 times every 16384 samples.

Steps to reproduce

  1. Get some device that runs MuseScore 4 and has an audio output with 8ch support. You can also use virtual devices.
  2. Configure the output device to have 2ch.
  3. Launch MuseScore 4.
  4. Create an empty score with piano part.
  5. Play the A4 note with Grand Piano from Muse Sound.
  6. Quit MuseScore 4.
  7. Configure the output device to have 8ch.
  8. Repeat the step 3 through step 5.
  9. You'll hear the difference of these two.

Screenshots/Screen recordings

Analysis of A4 note played with Piano from Muse Sound, recorded with Audacity (Mixed down to stereo by Voicemeeter Banana) Spectrum analysis (`Blackman‐Harris` window, 131072 samples) ![image](https://github.com/musescore/MuseScore/assets/31585494/898af739-f45b-47da-87f0-3ce93d2d6cf2) The peak was at around 1780 Hz. Waveform overview (truncated before the place the audio got messed up by either the other software or my hardware) ![image](https://github.com/musescore/MuseScore/assets/31585494/c4d045e2-b1aa-4b66-bfc8-6ad53ec949d4) Close-up ![image](https://github.com/musescore/MuseScore/assets/31585494/c847f4b4-f1f9-4280-ac09-8627bed5399d) It shows the repetitive sections consist of 8 copies. Further close-up ![image](https://github.com/musescore/MuseScore/assets/31585494/261e9bcf-6b6f-432b-9cb2-c9dcb5295ba3) It shows the duration of repeated sections are around 2048 samples each. Standard Autocorrelation analysis (`Rectangular` window, 16384 samples) ![image](https://github.com/musescore/MuseScore/assets/31585494/fe4b100a-1d45-4615-8ad2-e699e081e23e) A peak was found at `0.0107s (94 Hz)`, which roughly matches the $2048/192000 = 0.010666666... [s]$ .
Analysis of A4 note played with Dexed (configured to play a pure sinusoidal wave), recorded with Audacity (Mixed down to stereo by Voicemeeter Banana) Spectrum analysis (`Blackman‐Harris` window, 131072 samples) ![image](https://github.com/musescore/MuseScore/assets/31585494/fe036321-a698-401d-bb76-93b093077d2f) The peak was at around 1780 Hz again. Waveform overview ![image](https://github.com/musescore/MuseScore/assets/31585494/a66b48d5-511b-49f4-8f61-2ced30ffd751) Close-up ![image](https://github.com/musescore/MuseScore/assets/31585494/9d3ad243-feb5-4323-8627-cb8c72045e29) It's much harder to eyeball the repetitive sections. Further close-up ![image](https://github.com/musescore/MuseScore/assets/31585494/ba0539fa-c092-44ae-9910-cbea5f226c4e) Standard Autocorrelation analysis (`Rectangular` window, 16384 samples) ![image](https://github.com/musescore/MuseScore/assets/31585494/be52373b-3935-4e1e-8cbc-09455e429c15) Again, a peak was found at `0.0107s (94 Hz)`, which roughly matches the $2048/192000 = 0.010666666... [s]$ .

MuseScore Version

4.1.1-232071203, revision: github-musescore-musescore-e4d1ddf

Regression

I don't know

Operating system

Windows 11 Home 22H2 (22621.2134)

Additional context

cbjeukendrup commented 1 year ago

@bkunda I think this is a duplicate of #17648

MineCake147E commented 1 year ago

Oh, sorry. It's my fault. Should I close it then?