mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-01-05 15:56:49 +00:00
Audio/AL: Request our default sampling rate (48kHz) from AL when creating the
context. Otherwise AL might downsample and output in 44.1kHz unnecessarily, which happens at least on my system. Also tested on an audio device that doesn't support 48kHz to makes sure that still works.
This commit is contained in:
parent
5129d0da45
commit
a47bda026b
@ -14,10 +14,12 @@ LOG_CHANNEL(OpenAL);
|
||||
OpenALBackend::OpenALBackend()
|
||||
: AudioBackend()
|
||||
{
|
||||
ALCint attribs[] = {ALC_FREQUENCY, DEFAULT_AUDIO_SAMPLING_RATE, 0, 0};
|
||||
|
||||
ALCdevice* m_device = alcOpenDevice(nullptr);
|
||||
checkForAlcError("alcOpenDevice");
|
||||
|
||||
ALCcontext* m_context = alcCreateContext(m_device, nullptr);
|
||||
ALCcontext* m_context = alcCreateContext(m_device, attribs);
|
||||
checkForAlcError("alcCreateContext");
|
||||
|
||||
alcMakeContextCurrent(m_context);
|
||||
|
Loading…
Reference in New Issue
Block a user