diff options
author | Chris Robinson <[email protected]> | 2019-11-29 08:33:46 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2019-11-29 08:33:46 -0800 |
commit | 7ff165b09562b6942160803b0ea713ff4c911354 (patch) | |
tree | c7eddb8bb61bafc7ccdfc7f3f23f998176118cfc /alc/mixer | |
parent | 34edd3a9141775f04893fd56622f36a47af558b4 (diff) |
Use unsigned for array indices
Diffstat (limited to 'alc/mixer')
-rw-r--r-- | alc/mixer/hrtfbase.h | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/alc/mixer/hrtfbase.h b/alc/mixer/hrtfbase.h index 4a6eab50..942c56c3 100644 --- a/alc/mixer/hrtfbase.h +++ b/alc/mixer/hrtfbase.h @@ -22,10 +22,9 @@ inline void MixHrtfBase(const float *InSamples, float2 *RESTRICT AccumSamples, c const float gainstep{hrtfparams->GainStep}; const float gain{hrtfparams->Gain}; - ALsizei Delay[2]{ + size_t Delay[2]{ HRTF_HISTORY_LENGTH - hrtfparams->Delay[0], HRTF_HISTORY_LENGTH - hrtfparams->Delay[1] }; - ASSUME(Delay[0] >= 0 && Delay[1] >= 0); float stepcount{0.0f}; for(size_t i{0u};i < BufferSize;++i) { @@ -53,10 +52,9 @@ inline void MixHrtfBlendBase(const float *InSamples, float2 *RESTRICT AccumSampl ASSUME(BufferSize > 0); - ALsizei Delay[2]{ + size_t Delay[2]{ HRTF_HISTORY_LENGTH - oldparams->Delay[0], HRTF_HISTORY_LENGTH - oldparams->Delay[1] }; - ASSUME(Delay[0] >= 0 && Delay[1] >= 0); float stepcount{0.0f}; for(size_t i{0u};i < BufferSize;++i) { @@ -70,7 +68,6 @@ inline void MixHrtfBlendBase(const float *InSamples, float2 *RESTRICT AccumSampl Delay[0] = HRTF_HISTORY_LENGTH - newparams->Delay[0]; Delay[1] = HRTF_HISTORY_LENGTH - newparams->Delay[1]; - ASSUME(Delay[0] >= 0 && Delay[1] >= 0); stepcount = 0.0f; for(size_t i{0u};i < BufferSize;++i) { |