aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Alc/backends/dsound.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/Alc/backends/dsound.c b/Alc/backends/dsound.c
index fee1fd98..cde1aaf1 100644
--- a/Alc/backends/dsound.c
+++ b/Alc/backends/dsound.c
@@ -444,9 +444,9 @@ static ALCboolean ALCdsoundPlayback_reset(ALCdsoundPlayback *self)
hr = IDirectSound_GetSpeakerConfig(self->DS, &speakers);
if(SUCCEEDED(hr))
{
+ speakers = DSSPEAKER_CONFIG(speakers);
if(!(device->Flags&DEVICE_CHANNELS_REQUEST))
{
- speakers = DSSPEAKER_CONFIG(speakers);
if(speakers == DSSPEAKER_MONO)
device->FmtChans = DevFmtMono;
else if(speakers == DSSPEAKER_STEREO || speakers == DSSPEAKER_HEADPHONE)
@@ -462,6 +462,8 @@ static ALCboolean ALCdsoundPlayback_reset(ALCdsoundPlayback *self)
else
ERR("Unknown system speaker config: 0x%lx\n", speakers);
}
+ device->IsHeadphones = (device->FmtChans == DevFmtStereo &&
+ speakers == DSSPEAKER_HEADPHONE);
switch(device->FmtChans)
{