mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-12 09:01:16 +00:00
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:
parent
f32e598184
commit
60bbef62f1
@ -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
|
||||
|
@ -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);
|
||||
|
||||
/**
|
||||
|
@ -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;
|
||||
|
Loading…
Reference in New Issue
Block a user