mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-28 15:02:01 +00:00
- Fixed: The softsynths did not reset the tempo to its initial value when restarting a song.
SVN r3804 (trunk)
This commit is contained in:
parent
26f9540d3c
commit
6e81216bbd
1 changed files with 7 additions and 1 deletions
|
@ -944,7 +944,13 @@ int MIDIStreamer::FillBuffer(int buffer_num, int max_events, DWORD max_time)
|
||||||
if (Restarting)
|
if (Restarting)
|
||||||
{
|
{
|
||||||
Restarting = false;
|
Restarting = false;
|
||||||
events = WriteStopNotes(events); // Stop all notes in case any were left hanging.
|
// Reset the tempo to the inital value.
|
||||||
|
events[0] = 0; // dwDeltaTime
|
||||||
|
events[1] = 0; // dwStreamID
|
||||||
|
events[2] = (MEVT_TEMPO << 24) | InitialTempo; // dwEvent
|
||||||
|
events += 3;
|
||||||
|
// Stop all notes in case any were left hanging.
|
||||||
|
events = WriteStopNotes(events);
|
||||||
DoRestart();
|
DoRestart();
|
||||||
}
|
}
|
||||||
events = MakeEvents(events, max_event_p, max_time);
|
events = MakeEvents(events, max_event_p, max_time);
|
||||||
|
|
Loading…
Reference in a new issue