Change: Invalidate music volume when restarting music playback on Windows. (#11836)

This commit is contained in:
Peter Nelson
2024-01-19 17:01:36 +00:00
committed by GitHub
parent 6a2c37b4ed
commit 9cf47af490
2 changed files with 8 additions and 1 deletions

View File

@@ -651,6 +651,9 @@ static void MidiThreadProc()
TransmitNotesOff(_buffer, block_time, cur_time);
MemSetT<byte>(channel_volumes, 127, lengthof(channel_volumes));
/* Invalidate current volume. */
current_volume = UINT8_MAX;
last_volume_time = 0;
/* Take the current time plus the preload time as the music start time. */
clock->GetTime(&playback_start_time);