diff options
-rw-r--r-- | alc/mixer/hrtfbase.h | 6 | ||||
-rw-r--r-- | alc/mixer/mixer_c.cpp | 6 | ||||
-rw-r--r-- | alc/mixer/mixer_neon.cpp | 6 | ||||
-rw-r--r-- | alc/mixer/mixer_sse.cpp | 6 |
4 files changed, 12 insertions, 12 deletions
diff --git a/alc/mixer/hrtfbase.h b/alc/mixer/hrtfbase.h index ed40328c..7cc65640 100644 --- a/alc/mixer/hrtfbase.h +++ b/alc/mixer/hrtfbase.h @@ -9,8 +9,8 @@ #include "voice.h" -using ApplyCoeffsT = void(&)(float2 *RESTRICT Values, const ALuint irSize, const HrirArray &Coeffs, - const float left, const float right); +using ApplyCoeffsT = void(&)(float2 *RESTRICT Values, const uint_fast32_t irSize, + const HrirArray &Coeffs, const float left, const float right); template<ApplyCoeffsT ApplyCoeffs> inline void MixHrtfBase(const float *InSamples, float2 *RESTRICT AccumSamples, const ALuint IrSize, @@ -85,7 +85,7 @@ inline void MixDirectHrtfBase(FloatBufferLine &LeftOut, FloatBufferLine &RightOu { ASSUME(BufferSize > 0); - const ALuint IrSize{State->IrSize}; + const uint_fast32_t IrSize{State->IrSize}; auto coeff_iter = State->Coeffs.begin(); for(const FloatBufferLine &input : InSamples) diff --git a/alc/mixer/mixer_c.cpp b/alc/mixer/mixer_c.cpp index 9858a4b4..8a58ff10 100644 --- a/alc/mixer/mixer_c.cpp +++ b/alc/mixer/mixer_c.cpp @@ -84,11 +84,11 @@ const float *DoResample(const InterpState *state, const float *RESTRICT src, ALu return dst.data(); } -inline void ApplyCoeffs(float2 *RESTRICT Values, const ALuint IrSize, const HrirArray &Coeffs, - const float left, const float right) +inline void ApplyCoeffs(float2 *RESTRICT Values, const uint_fast32_t IrSize, + const HrirArray &Coeffs, const float left, const float right) { ASSUME(IrSize >= MIN_IR_LENGTH); - for(ALuint c{0};c < IrSize;++c) + for(size_t c{0};c < IrSize;++c) { Values[c][0] += Coeffs[c][0] * left; Values[c][1] += Coeffs[c][1] * right; diff --git a/alc/mixer/mixer_neon.cpp b/alc/mixer/mixer_neon.cpp index ee5b11a2..b62213d4 100644 --- a/alc/mixer/mixer_neon.cpp +++ b/alc/mixer/mixer_neon.cpp @@ -24,8 +24,8 @@ namespace { #define FRAC_PHASE_BITDIFF (FRACTIONBITS - BSINC_PHASE_BITS) #define FRAC_PHASE_DIFFONE (1<<FRAC_PHASE_BITDIFF) -inline void ApplyCoeffs(float2 *RESTRICT Values, const ALuint IrSize, const HrirArray &Coeffs, - const float left, const float right) +inline void ApplyCoeffs(float2 *RESTRICT Values, const uint_fast32_t IrSize, + const HrirArray &Coeffs, const float left, const float right) { float32x4_t leftright4; { @@ -36,7 +36,7 @@ inline void ApplyCoeffs(float2 *RESTRICT Values, const ALuint IrSize, const Hrir } ASSUME(IrSize >= MIN_IR_LENGTH); - for(ALuint c{0};c < IrSize;c += 2) + for(size_t c{0};c < IrSize;c += 2) { float32x4_t vals = vld1q_f32(&Values[c][0]); float32x4_t coefs = vld1q_f32(&Coeffs[c][0]); diff --git a/alc/mixer/mixer_sse.cpp b/alc/mixer/mixer_sse.cpp index db60776d..2acfc0be 100644 --- a/alc/mixer/mixer_sse.cpp +++ b/alc/mixer/mixer_sse.cpp @@ -25,8 +25,8 @@ namespace { #define MLA4(x, y, z) _mm_add_ps(x, _mm_mul_ps(y, z)) -inline void ApplyCoeffs(float2 *RESTRICT Values, const ALuint IrSize, const HrirArray &Coeffs, - const float left, const float right) +inline void ApplyCoeffs(float2 *RESTRICT Values, const uint_fast32_t IrSize, + const HrirArray &Coeffs, const float left, const float right) { const __m128 lrlr{_mm_setr_ps(left, right, left, right)}; @@ -43,7 +43,7 @@ inline void ApplyCoeffs(float2 *RESTRICT Values, const ALuint IrSize, const Hrir imp0 = _mm_mul_ps(lrlr, coeffs); vals = _mm_add_ps(imp0, vals); _mm_storel_pi(reinterpret_cast<__m64*>(&Values[0][0]), vals); - ALuint td{(IrSize>>1) - 1}; + uint_fast32_t td{(IrSize>>1) - 1}; size_t i{1}; do { coeffs = _mm_load_ps(&Coeffs[i+1][0]); |