diff --git a/src/BizHawk.Client.EmuHawk/MainForm.Events.cs b/src/BizHawk.Client.EmuHawk/MainForm.Events.cs index 5c480d211a..9c879da4b8 100644 --- a/src/BizHawk.Client.EmuHawk/MainForm.Events.cs +++ b/src/BizHawk.Client.EmuHawk/MainForm.Events.cs @@ -924,7 +924,7 @@ namespace BizHawk.Client.EmuHawk if (form.ApplyNewSoundDevice) { Sound.Dispose(); - Sound = new Sound(Handle, Config, Emulator.VsyncRate); + Sound = new Sound(Handle, Config, () => Emulator.VsyncRate()); Sound.StartSound(); } else diff --git a/src/BizHawk.Client.EmuHawk/MainForm.cs b/src/BizHawk.Client.EmuHawk/MainForm.cs index 61f4b692b1..76a554f98d 100644 --- a/src/BizHawk.Client.EmuHawk/MainForm.cs +++ b/src/BizHawk.Client.EmuHawk/MainForm.cs @@ -433,7 +433,7 @@ namespace BizHawk.Client.EmuHawk InputManager.AutofireStickyXorAdapter.SetOnOffPatternFromConfig(Config.AutofireOn, Config.AutofireOff); try { - Sound = new Sound(Handle, Config, Emulator.VsyncRate); + Sound = new Sound(Handle, Config, () => Emulator.VsyncRate()); } catch { @@ -446,7 +446,7 @@ namespace BizHawk.Client.EmuHawk ShowMessageBox(owner: null, message, "Initialization Error", MessageBoxButtons.OK, MessageBoxIcon.Error); Config.SoundOutputMethod = ESoundOutputMethod.Dummy; - Sound = new Sound(Handle, Config, Emulator.VsyncRate); + Sound = new Sound(Handle, Config, () => Emulator.VsyncRate()); } Sound.StartSound(); @@ -3324,7 +3324,7 @@ namespace BizHawk.Client.EmuHawk else { _currentSoundProvider.SetSyncMode(SyncSoundMode.Sync); - _aviSoundInputAsync = new SyncToAsyncProvider(Emulator.VsyncRate, _currentSoundProvider); + _aviSoundInputAsync = new SyncToAsyncProvider(() => Emulator.VsyncRate(), _currentSoundProvider); } }