diff --git a/src/sound/timiditypp/playmidi.cpp b/src/sound/timiditypp/playmidi.cpp index 961a7b61d..4ffa768c8 100644 --- a/src/sound/timiditypp/playmidi.cpp +++ b/src/sound/timiditypp/playmidi.cpp @@ -131,11 +131,11 @@ CUSTOM_CVAR(Int, timidity_chorus, 0, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) CUSTOM_CVAR(Bool, timidity_surround_chorus, false, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) { - ChangeVarSync(TimidityPlus::timidity_surround_chorus, *self); if (currSong != nullptr && currSong->GetDeviceType() == MDEV_TIMIDITY) { MIDIDeviceChanged(-1, true); } + ChangeVarSync(TimidityPlus::timidity_surround_chorus, *self); } CUSTOM_CVAR(Bool, timidity_channel_pressure, false, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) diff --git a/src/sound/timiditypp/reverb.cpp b/src/sound/timiditypp/reverb.cpp index c83e1f568..ae7401143 100644 --- a/src/sound/timiditypp/reverb.cpp +++ b/src/sound/timiditypp/reverb.cpp @@ -1878,6 +1878,14 @@ void Reverb::do_ch_stereo_chorus(int32_t *buf, int32_t count, InfoStereoChorus * return; } + if (bufL == nullptr) + { + set_delay(&(info->delayL), info->rpt0); + set_delay(&(info->delayR), info->rpt0); + bufL = info->delayL.buf; + bufR = info->delayR.buf; + } + /* LFO */ f0 = imuldiv24(lfobufL[imuldiv24(lfocnt, icycle)], depth); spt0 = wpt0 - pdelay - (f0 >> 8); /* integral part of delay */