aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/effects
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2018-11-19 19:13:44 -0800
committerChris Robinson <[email protected]>2018-11-19 19:13:44 -0800
commit7f3584ec4cef13e3e7b9159c90b0d43246d08a42 (patch)
tree4f9e32bee7fc68f21166594b5a246e644cf626c7 /Alc/effects
parent4810def6137c7bc865cfd87346a515ca1bc3a646 (diff)
Fix the reverb buffer size calculation
Diffstat (limited to 'Alc/effects')
-rw-r--r--Alc/effects/reverb.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/Alc/effects/reverb.cpp b/Alc/effects/reverb.cpp
index 8b63e473..229cd316 100644
--- a/Alc/effects/reverb.cpp
+++ b/Alc/effects/reverb.cpp
@@ -535,9 +535,10 @@ static ALboolean AllocLines(const ALuint frequency, ReverbState *State)
totalSamples += CalcLineLength(length, totalSamples, frequency, 0,
&State->mLate.Delay);
+ totalSamples *= NUM_LINES;
if(totalSamples != State->mSampleBuffer.size())
{
- State->mSampleBuffer.resize(sizeof(ALfloat[NUM_LINES]) * totalSamples);
+ State->mSampleBuffer.resize(totalSamples);
State->mSampleBuffer.shrink_to_fit();
}