aboutsummaryrefslogtreecommitdiffstats
path: root/alc/bformatdec.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'alc/bformatdec.cpp')
-rw-r--r--alc/bformatdec.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/alc/bformatdec.cpp b/alc/bformatdec.cpp
index c2137b33..17b0d3d9 100644
--- a/alc/bformatdec.cpp
+++ b/alc/bformatdec.cpp
@@ -49,7 +49,7 @@ inline auto GetAmbiScales(AmbDecScale scaletype) noexcept -> const std::array<fl
BFormatDec::BFormatDec(const AmbDecConf *conf, const bool allow_2band, const ALuint inchans,
- const ALuint srate, const ALsizei (&chanmap)[MAX_OUTPUT_CHANNELS])
+ const ALuint srate, const ALuint (&chanmap)[MAX_OUTPUT_CHANNELS])
{
mDualBand = allow_2band && (conf->FreqBands == 2);
if(!mDualBand)
@@ -64,7 +64,7 @@ BFormatDec::BFormatDec(const AmbDecConf *conf, const bool allow_2band, const ALu
mNumChannels = inchans;
mEnabled = std::accumulate(std::begin(chanmap), std::begin(chanmap)+conf->Speakers.size(), 0u,
- [](ALuint mask, const ALsizei &chan) noexcept -> ALuint
+ [](ALuint mask, const ALuint &chan) noexcept -> ALuint
{ return mask | (1 << chan); }
);
@@ -120,21 +120,20 @@ BFormatDec::BFormatDec(const AmbDecConf *conf, const bool allow_2band, const ALu
BFormatDec::BFormatDec(const ALuint inchans, const ALsizei chancount,
const ChannelDec (&chancoeffs)[MAX_OUTPUT_CHANNELS],
- const ALsizei (&chanmap)[MAX_OUTPUT_CHANNELS])
+ const ALuint (&chanmap)[MAX_OUTPUT_CHANNELS])
{
mSamples.resize(2);
mNumChannels = inchans;
ASSUME(chancount > 0);
mEnabled = std::accumulate(std::begin(chanmap), std::begin(chanmap)+chancount, 0u,
- [](ALuint mask, const ALsizei &chan) noexcept -> ALuint
+ [](ALuint mask, const ALuint &chan) noexcept -> ALuint
{ return mask | (1 << chan); }
);
const ChannelDec *incoeffs{chancoeffs};
- auto set_coeffs = [this,inchans,&incoeffs](const ALsizei chanidx) noexcept -> void
+ auto set_coeffs = [this,inchans,&incoeffs](const ALuint chanidx) noexcept -> void
{
- ASSUME(chanidx >= 0);
ALfloat (&mtx)[MAX_AMBI_CHANNELS] = mMatrix.Single[chanidx];
const ALfloat (&coeffs)[MAX_AMBI_CHANNELS] = *(incoeffs++);