Fix subtle bug in renderSound
Bug as follows: renderSound was true when any of the following: _currAviWriter!=null&&_currAviWriter.UsesAudio !IsTurboing || _currAviWriter!=null So, if _currAviWriter!=null, it didn't matter if it has the UsesAudio flag on or not.
This commit is contained in:
parent
4bd6608940
commit
68a362c8ff
|
@ -2731,7 +2731,6 @@ namespace BizHawk.Client.EmuHawk
|
||||||
|
|
||||||
float atten = 0;
|
float atten = 0;
|
||||||
|
|
||||||
var coreskipaudio = false;
|
|
||||||
if (runFrame || force)
|
if (runFrame || force)
|
||||||
{
|
{
|
||||||
var isFastForwarding = Global.ClientControls["Fast Forward"] || IsTurboing;
|
var isFastForwarding = Global.ClientControls["Fast Forward"] || IsTurboing;
|
||||||
|
@ -2824,19 +2823,12 @@ namespace BizHawk.Client.EmuHawk
|
||||||
|
|
||||||
Global.MovieSession.HandleMovieOnFrameLoop();
|
Global.MovieSession.HandleMovieOnFrameLoop();
|
||||||
|
|
||||||
coreskipaudio = IsTurboing && _currAviWriter == null;
|
|
||||||
|
|
||||||
//why not skip audio if the user doesnt want sound
|
//why not skip audio if the user doesnt want sound
|
||||||
if (!Global.Config.SoundEnabled)
|
bool renderSound = Global.Config.SoundEnabled || !IsTurboing;
|
||||||
coreskipaudio = true;
|
renderSound |= (_currAviWriter != null && _currAviWriter.UsesAudio);
|
||||||
|
|
||||||
{
|
bool render = !_throttle.skipnextframe || (_currAviWriter != null && _currAviWriter.UsesVideo);
|
||||||
bool render = !_throttle.skipnextframe;
|
Global.Emulator.FrameAdvance(render, renderSound);
|
||||||
bool renderSound = !coreskipaudio;
|
|
||||||
if (_currAviWriter != null && _currAviWriter.UsesVideo) render = true;
|
|
||||||
if (_currAviWriter != null && _currAviWriter.UsesAudio) renderSound = true;
|
|
||||||
Global.Emulator.FrameAdvance(render, renderSound);
|
|
||||||
}
|
|
||||||
|
|
||||||
Global.MovieSession.HandleMovieAfterFrameLoop();
|
Global.MovieSession.HandleMovieAfterFrameLoop();
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue