aboutsummaryrefslogtreecommitdiffstats
path: root/alc/bformatdec.cpp
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2019-08-20 00:27:28 -0700
committerChris Robinson <[email protected]>2019-08-20 00:27:28 -0700
commit8fd90334a13608a781e36fc830cd79bf746edd42 (patch)
treecefd2023a67138e29db07a32d114dd1ed5a00b9a /alc/bformatdec.cpp
parent34a61122f64d6295f50508cc6945350a5be04924 (diff)
Pass the MixRow buffer size as a span
Diffstat (limited to 'alc/bformatdec.cpp')
-rw-r--r--alc/bformatdec.cpp13
1 files changed, 7 insertions, 6 deletions
diff --git a/alc/bformatdec.cpp b/alc/bformatdec.cpp
index ce4c4b3b..7d681bc6 100644
--- a/alc/bformatdec.cpp
+++ b/alc/bformatdec.cpp
@@ -162,10 +162,11 @@ void BFormatDec::process(const al::span<FloatBufferLine> OutBuffer,
{
if LIKELY(enabled&1)
{
- MixRowSamples(outbuf.data(), {(*mixmtx)[sHFBand], mNumChannels},
- mSamplesHF->data(), mSamplesHF->size(), SamplesToDo);
- MixRowSamples(outbuf.data(), {(*mixmtx)[sLFBand], mNumChannels},
- mSamplesLF->data(), mSamplesLF->size(), SamplesToDo);
+ const al::span<float> outspan{outbuf.data(), outbuf.data()+SamplesToDo};
+ MixRowSamples(outspan, {(*mixmtx)[sHFBand], mNumChannels}, mSamplesHF->data(),
+ mSamplesHF->size());
+ MixRowSamples(outspan, {(*mixmtx)[sLFBand], mNumChannels}, mSamplesLF->data(),
+ mSamplesLF->size());
}
++mixmtx;
enabled >>= 1;
@@ -178,8 +179,8 @@ void BFormatDec::process(const al::span<FloatBufferLine> OutBuffer,
for(FloatBufferLine &outbuf : OutBuffer)
{
if LIKELY(enabled&1)
- MixRowSamples(outbuf.data(), {*mixmtx, mNumChannels}, InSamples->data(),
- InSamples->size(), SamplesToDo);
+ MixRowSamples({outbuf.data(), outbuf.data()+SamplesToDo}, {*mixmtx, mNumChannels},
+ InSamples->data(), InSamples->size());
++mixmtx;
enabled >>= 1;
}