From e4570189211c3c0fef6b8c7a3cb1eae3a3d32cb3 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Thu, 1 Apr 2021 03:44:26 -0700 Subject: Avoid passing an array of pointers --- alc/voice.cpp | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) (limited to 'alc') diff --git a/alc/voice.cpp b/alc/voice.cpp index 7e761b29..891bc3dc 100644 --- a/alc/voice.cpp +++ b/alc/voice.cpp @@ -636,15 +636,9 @@ void Voice::mix(const State vstate, ALCcontext *Context, const uint SamplesToDo) if(mDecoder) { - std::array samples{{mVoiceSamples[0].data() + MaxResamplerEdge, - mVoiceSamples[1].data() + MaxResamplerEdge, - mVoiceSamples[2].data() + MaxResamplerEdge, - nullptr}}; - if(mVoiceSamples.size() > 3) - samples[3] = mVoiceSamples[3].data() + MaxResamplerEdge; const size_t srcOffset{(increment*DstBufferSize + DataPosFrac)>>MixerFracBits}; SrcBufferSize = SrcBufferSize - PostPadding + MaxResamplerEdge; - mDecoder->decode(samples, SrcBufferSize, srcOffset); + mDecoder->decode(mVoiceSamples, MaxResamplerEdge, SrcBufferSize, srcOffset); } } -- cgit v1.2.3