bug 1198656 interpret null ConvolverNode mBuffer as a buffer of zeros r=padenot
authorKarl Tomlinson <karlt+@karlt.net>
Fri, 21 Aug 2015 17:14:14 +1200
changeset 261736 b27cf1d8880741a8cab12cd7be23b6a084e08e35
parent 261735 2b9a5c8a0a4a31cfdac12d053a6649f967d3d257
child 261737 5376e4042cf34a8845250397d670275e9e000cc4
push id29355
push usercbook@mozilla.com
push dateFri, 11 Sep 2015 14:37:04 +0000
treeherdermozilla-central@19f806034f67 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerspadenot
bugs1198656
milestone43.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
bug 1198656 interpret null ConvolverNode mBuffer as a buffer of zeros r=padenot Zero output even when normalize is set is consistent with http://webaudio.github.io/web-audio-api/#widl-ConvolverNode-normalize due to the specified isinf() test.
dom/media/webaudio/ConvolverNode.cpp
--- a/dom/media/webaudio/ConvolverNode.cpp
+++ b/dom/media/webaudio/ConvolverNode.cpp
@@ -102,17 +102,17 @@ public:
   }
 
   virtual void ProcessBlock(AudioNodeStream* aStream,
                             const AudioBlock& aInput,
                             AudioBlock* aOutput,
                             bool* aFinished) override
   {
     if (!mReverb) {
-      *aOutput = aInput;
+      aOutput->SetNull(WEBAUDIO_BLOCK_SIZE);
       return;
     }
 
     AudioBlock input = aInput;
     if (aInput.IsNull()) {
       if (mLeftOverData > 0) {
         mLeftOverData -= WEBAUDIO_BLOCK_SIZE;
         input.AllocateChannels(1);