aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/mixvoice.cpp
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2019-03-09 21:54:15 -0800
committerChris Robinson <[email protected]>2019-03-09 21:54:15 -0800
commit6a95189ef66bee5dc600f33c5518a60de042a225 (patch)
tree80e7a66164b47d66702247aff22e6c5750c610c1 /Alc/mixvoice.cpp
parent106671d45185576e9386eaf0c27211446c8ebce5 (diff)
Fix for MSVC decaying arrays to pointers with ?:
Diffstat (limited to 'Alc/mixvoice.cpp')
-rw-r--r--Alc/mixvoice.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/Alc/mixvoice.cpp b/Alc/mixvoice.cpp
index 09c19136..3366aa61 100644
--- a/Alc/mixvoice.cpp
+++ b/Alc/mixvoice.cpp
@@ -627,8 +627,8 @@ void MixSource(ALvoice *voice, const ALuint SourceID, ALCcontext *Context, const
const ALfloat *samples{DoFilters(&parms.LowPass, &parms.HighPass,
Device->FilteredData, ResampledData, DstBufferSize, voice->Direct.FilterType)};
- const ALfloat (&TargetGains)[MAX_OUTPUT_CHANNELS] =
- UNLIKELY(vstate==ALvoice::Stopping) ? SilentTarget : parms.Gains.Target;
+ const ALfloat *TargetGains{UNLIKELY(vstate==ALvoice::Stopping) ? SilentTarget :
+ parms.Gains.Target};
if(!(voice->Flags&VOICE_HAS_HRTF))
{
if(!(voice->Flags&VOICE_HAS_NFC))
@@ -643,7 +643,7 @@ void MixSource(ALvoice *voice, const ALuint SourceID, ALCcontext *Context, const
ALfloat (&nfcsamples)[BUFFERSIZE] = Device->NfcSampleData;
ALsizei chanoffset{voice->Direct.ChannelsPerOrder[0]};
using FilterProc = void (NfcFilter::*)(float*,const float*,int);
- auto apply_nfc = [voice,&parms,samples,&TargetGains,DstBufferSize,Counter,OutPos,&chanoffset,&nfcsamples](FilterProc process, ALsizei order) -> void
+ auto apply_nfc = [voice,&parms,samples,TargetGains,DstBufferSize,Counter,OutPos,&chanoffset,&nfcsamples](FilterProc process, ALsizei order) -> void
{
if(voice->Direct.ChannelsPerOrder[order] < 1)
return;
@@ -740,8 +740,8 @@ void MixSource(ALvoice *voice, const ALuint SourceID, ALCcontext *Context, const
const ALfloat *samples{DoFilters(&parms.LowPass, &parms.HighPass,
FilterBuf, ResampledData, DstBufferSize, send.FilterType)};
- const ALfloat (&TargetGains)[MAX_OUTPUT_CHANNELS] =
- UNLIKELY(vstate==ALvoice::Stopping) ? SilentTarget : parms.Gains.Target;
+ const ALfloat *TargetGains{UNLIKELY(vstate==ALvoice::Stopping) ? SilentTarget :
+ parms.Gains.Target};
MixSamples(samples, send.Channels, send.Buffer, parms.Gains.Current,
TargetGains, Counter, OutPos, DstBufferSize);
};