b=967924 correct resampler input buffer sample count estimate math r=padenot

--HG--
extra : transplant_source : %15%90%0C%22_%99%BFK%14%93%28L%23hZ1%FE%B7NB
This commit is contained in:
Karl Tomlinson 2014-02-06 08:15:31 +13:00
parent f7eedc6c76
commit e3e1b11c56

View File

@ -203,7 +203,7 @@ public:
uint32_t num, den;
speex_resampler_get_ratio(resampler, &num, &den);
uint32_t inputLimit = std::min(availableInInputBuffer,
availableInOutputBuffer * den / num + 10);
availableInOutputBuffer * num / den + 10);
for (uint32_t i = 0; true; ) {
uint32_t inSamples = inputLimit;
const float* inputData = mBuffer->GetData(i) + aBufferOffset;