diff options
| author | Mary <me@thog.eu> | 2020-08-18 21:03:55 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-08-18 21:03:55 +0200 |
| commit | 5b26e4ef94afca8450f07c42393180e3c97f9c00 (patch) | |
| tree | 5c698591bd557711a487430ba06921b10ce53761 /Ryujinx.Audio.Renderer | |
| parent | a389dd59bd881cf2cff09a1f67f5c30de61123e6 (diff) | |
Misc audio fixes (#1348)
Changes:
Implement software surround downmixing (fix #796).
Fix a crash when no audio renderer were created when stopping emulation.
NOTE: This PR also disable support of 5.1 surround on the OpenAL backend as we cannot detect if the hardware directly support it. (the downmixing applied by OpenAL on Windows is terribly slow)
Diffstat (limited to 'Ryujinx.Audio.Renderer')
| -rw-r--r-- | Ryujinx.Audio.Renderer/Dsp/AudioProcessor.cs | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/Ryujinx.Audio.Renderer/Dsp/AudioProcessor.cs b/Ryujinx.Audio.Renderer/Dsp/AudioProcessor.cs index 90f6cd51..674f20f9 100644 --- a/Ryujinx.Audio.Renderer/Dsp/AudioProcessor.cs +++ b/Ryujinx.Audio.Renderer/Dsp/AudioProcessor.cs @@ -54,6 +54,11 @@ namespace Ryujinx.Audio.Renderer.Dsp private long _playbackEnds; private ManualResetEvent _event; + public AudioProcessor() + { + _event = new ManualResetEvent(false); + } + public void SetOutputDevices(HardwareDevice[] outputDevices) { _outputDevices = outputDevices; @@ -63,7 +68,7 @@ namespace Ryujinx.Audio.Renderer.Dsp { _mailbox = new Mailbox<MailboxMessage>(); _sessionCommandList = new RendererSession[RendererConstants.AudioRendererSessionCountMax]; - _event = new ManualResetEvent(false); + _event.Reset(); _lastTime = PerformanceCounter.ElapsedNanoseconds; StartThread(); |
