Module: wine Branch: master Commit: 80192b93ebd832570d6af97b80a3f29fb854627c URL: http://source.winehq.org/git/wine.git/?a=commit;h=80192b93ebd832570d6af97b80...
Author: Maarten Lankhorst maarten@codeweavers.com Date: Sat Oct 13 20:29:40 2007 +0200
dsound: Only warn for unsupported channels (or bits) when volume adjustment is done.
---
dlls/dsound/mixer.c | 10 +++++----- 1 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/dlls/dsound/mixer.c b/dlls/dsound/mixer.c index 2486e72..daa4e97 100644 --- a/dlls/dsound/mixer.c +++ b/dlls/dsound/mixer.c @@ -435,6 +435,11 @@ static LPBYTE DSOUND_MixerVol(const IDirectSoundBufferImpl *dsb, DWORD writepos, TRACE("left = %x, right = %x\n", dsb->volpan.dwTotalLeftAmpFactor, dsb->volpan.dwTotalRightAmpFactor);
+ if ((!(dsb->dsbd.dwFlags & DSBCAPS_CTRLPAN) || (dsb->volpan.lPan == 0)) && + (!(dsb->dsbd.dwFlags & DSBCAPS_CTRLVOLUME) || (dsb->volpan.lVolume == 0)) && + !(dsb->dsbd.dwFlags & DSBCAPS_CTRL3D)) + return NULL; /* Nothing to do */ + if (nChannels != 1 && nChannels != 2) { FIXME("There is no support for %d channels\n", nChannels); @@ -447,11 +452,6 @@ static LPBYTE DSOUND_MixerVol(const IDirectSoundBufferImpl *dsb, DWORD writepos, return NULL; }
- if ((!(dsb->dsbd.dwFlags & DSBCAPS_CTRLPAN) || (dsb->volpan.lPan == 0)) && - (!(dsb->dsbd.dwFlags & DSBCAPS_CTRLVOLUME) || (dsb->volpan.lVolume == 0)) && - !(dsb->dsbd.dwFlags & DSBCAPS_CTRL3D)) - return NULL; /* Nothing to do */ - if (dsb->device->tmp_buffer_len < len || !dsb->device->tmp_buffer) { dsb->device->tmp_buffer_len = len;