b=933304 Remove unnecessary channel count parameter from AudioBlockInPlaceScale r=padenot

--HG--
extra : transplant_source : s%04%B1%11%E9%F9%E2%92l%182%FFZm%81%E4/M%B3%BD
This commit is contained in:
Karl Tomlinson 2014-01-28 18:14:25 +13:00
parent f32e598184
commit 60bbef62f1
3 changed files with 2 additions and 4 deletions

View File

@ -156,10 +156,9 @@ AudioBlockCopyChannelWithScale(const float aInput[WEBAUDIO_BLOCK_SIZE],
void
AudioBlockInPlaceScale(float aBlock[WEBAUDIO_BLOCK_SIZE],
uint32_t aChannelCount,
float aScale)
{
AudioBufferInPlaceScale(aBlock, aScale, aChannelCount * WEBAUDIO_BLOCK_SIZE);
AudioBufferInPlaceScale(aBlock, aScale, WEBAUDIO_BLOCK_SIZE);
}
void

View File

@ -150,7 +150,6 @@ float AudioBufferPeakValue(const float* aInput, uint32_t aSize);
* In place gain. aScale == 1.0f should be optimized.
*/
void AudioBlockInPlaceScale(float aBlock[WEBAUDIO_BLOCK_SIZE],
uint32_t aChannelCount,
float aScale);
/**

View File

@ -288,7 +288,7 @@ AnalyserNode::AppendChunk(const AudioChunk& aChunk)
mBuffer.Elements() + mWriteIndex);
}
if (channelCount > 1) {
AudioBlockInPlaceScale(mBuffer.Elements() + mWriteIndex, 1,
AudioBlockInPlaceScale(mBuffer.Elements() + mWriteIndex,
1.0f / aChunk.mChannelData.Length());
}
mWriteIndex += chunkDuration;