Source/WebCore/ChangeLog

 12020-08-19 Clark Wang <clark_wang@apple.com>
 2
 3 Introduce StereoPannerNode Interface
 4 https://bugs.webkit.org/show_bug.cgi?id=215518
 5
 6 Reviewed by Darin Adler.
 7
 8 Added StereoPannerNode according to spec: https://www.w3.org/TR/webaudio/#stereopannernode.
 9 Used Chromium implementation for guidance: https://source.chromium.org/chromium/chromium/src/
 10 +/master:third_party/blink/renderer/modules/webaudio/stereo_panner_node.cc.
 11 Added in StereoPannerOptions and StereoPanner files as well. The latter used Chromium
 12 implementation for guidance: https://source.chromium.org/chromium/chromium/src/+
 13 /master:third_party/blink/renderer/platform/audio/stereo_panner.cc
 14
 15 Re-baselined existing tests. Some now fail due to missing automation rate.
 16
 17 * CMakeLists.txt:
 18 * DerivedSources-input.xcfilelist:
 19 * DerivedSources-output.xcfilelist:
 20 * DerivedSources.make:
 21 * Modules/webaudio/AudioNode.cpp:
 22 (WebCore::convertEnumerationToString):
 23 * Modules/webaudio/AudioNode.h:
 24 * Modules/webaudio/BaseAudioContext.cpp:
 25 (WebCore::BaseAudioContext::createStereoPanner):
 26 * Modules/webaudio/BaseAudioContext.h:
 27 * Modules/webaudio/BaseAudioContext.idl:
 28 * Modules/webaudio/StereoPannerNode.cpp: Added.
 29 (WebCore::StereoPannerNode::create):
 30 (WebCore::StereoPannerNode::StereoPannerNode):
 31 (WebCore::StereoPannerNode::~StereoPannerNode):
 32 (WebCore::StereoPannerNode::process):
 33 (WebCore::StereoPannerNode::initialize):
 34 (WebCore::StereoPannerNode::uninitialize):
 35 (WebCore::StereoPannerNode::listener):
 36 (WebCore::StereoPannerNode::setChannelCount):
 37 (WebCore::StereoPannerNode::setChannelCountMode):
 38 * Modules/webaudio/StereoPannerNode.h: Added.
 39 * Modules/webaudio/StereoPannerNode.idl: Added.
 40 * Modules/webaudio/StereoPannerOptions.h: Added.
 41 * Modules/webaudio/StereoPannerOptions.idl: Added.
 42 * Sources.txt:
 43 * WebCore.xcodeproj/project.pbxproj:
 44 * bindings/js/WebCoreBuiltinNames.h:
 45 * platform/audio/StereoPanner.cpp: Added.
 46 (WebCore::StereoPanner::create):
 47 (WebCore::StereoPanner::StereoPanner):
 48 (WebCore::StereoPanner::panWithSampleAccurateValues):
 49 (WebCore::StereoPanner::panToTargetValue):
 50 * platform/audio/StereoPanner.h: Added.
 51 (WebCore::StereoPanner::~StereoPanner):
 52 * platform/graphics/cocoa/SourceBufferParserWebM.cpp:
 53
1542020-08-18 Simon Fraser <simon.fraser@apple.com>
255
356 Turn off wheel event regions until we need them

Source/WebCore/CMakeLists.txt

@@set(WebCore_NON_SVG_IDL_FILES
507507 Modules/webaudio/PeriodicWave.idl
508508 Modules/webaudio/PeriodicWaveConstraints.idl
509509 Modules/webaudio/PeriodicWaveOptions.idl
 510 Modules/webaudio/StereoPannerNode.idl
 511 Modules/webaudio/StereoPannerOptions.idl
510512 Modules/webaudio/ScriptProcessorNode.idl
511513 Modules/webaudio/WaveShaperNode.idl
512514 Modules/webaudio/WaveShaperOptions.idl

Source/WebCore/DerivedSources-input.xcfilelist

@@$(PROJECT_DIR)/Modules/webaudio/PeriodicWave.idl
359359$(PROJECT_DIR)/Modules/webaudio/PeriodicWaveConstraints.idl
360360$(PROJECT_DIR)/Modules/webaudio/PeriodicWaveOptions.idl
361361$(PROJECT_DIR)/Modules/webaudio/ScriptProcessorNode.idl
 362$(PROJECT_DIR)/Modules/webaudio/StereoPannerNode.idl
 363$(PROJECT_DIR)/Modules/webaudio/StereoPannerOptions.idl
362364$(PROJECT_DIR)/Modules/webaudio/WaveShaperNode.idl
363365$(PROJECT_DIR)/Modules/webaudio/WaveShaperOptions.idl
364366$(PROJECT_DIR)/Modules/webaudio/WebKitAudioBufferSourceNode.idl

Source/WebCore/DerivedSources-output.xcfilelist

@@$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSSpeechSynthesisVoice.cpp
18921892$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSSpeechSynthesisVoice.h
18931893$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSStaticRange.cpp
18941894$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSStaticRange.h
 1895$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSStereoPannerNode.cpp
 1896$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSStereoPannerNode.h
 1897$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSStereoPannerOptions.cpp
 1898$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSStereoPannerOptions.h
18951899$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSStorage.cpp
18961900$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSStorage.h
18971901$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSStorageErrorCallback.cpp

Source/WebCore/DerivedSources.make

@@JS_BINDING_IDLS = \
440440 $(WebCore)/Modules/webaudio/PeriodicWaveConstraints.idl \
441441 $(WebCore)/Modules/webaudio/PeriodicWaveOptions.idl \
442442 $(WebCore)/Modules/webaudio/ScriptProcessorNode.idl \
 443 $(WebCore)/Modules/webaudio/StereoPannerNode.idl \
 444 $(WebCore)/Modules/webaudio/StereoPannerOptions.idl \
443445 $(WebCore)/Modules/webaudio/WaveShaperNode.idl \
444446 $(WebCore)/Modules/webaudio/WaveShaperOptions.idl \
445447 $(WebCore)/Modules/webaudio/WebKitAudioBufferSourceNode.idl \

Source/WebCore/Modules/webaudio/AudioNode.cpp

@@String convertEnumerationToString(AudioNode::NodeType enumerationValue)
7070 MAKE_STATIC_STRING_IMPL("NodeTypeWaveShaper"),
7171 MAKE_STATIC_STRING_IMPL("NodeTypeBasicInspector"),
7272 MAKE_STATIC_STRING_IMPL("NodeTypeConstant"),
 73 MAKE_STATIC_STRING_IMPL("NodeTypeStereo"),
7374 MAKE_STATIC_STRING_IMPL("NodeTypeEnd"),
7475 };
7576 static_assert(static_cast<size_t>(AudioNode::NodeTypeUnknown) == 0, "AudioNode::NodeTypeUnknown is not 0 as expected");

@@String convertEnumerationToString(AudioNode::NodeType enumerationValue)
9293 static_assert(static_cast<size_t>(AudioNode::NodeTypeWaveShaper) == 17, "AudioNode::NodeTypeWaveShaper is not 17 as expected");
9394 static_assert(static_cast<size_t>(AudioNode::NodeTypeBasicInspector) == 18, "AudioNode::NodeTypeBasicInspector is not 18 as expected");
9495 static_assert(static_cast<size_t>(AudioNode::NodeTypeConstant) == 19, "AudioNode::NodeTypeEnd is not 19 as expected");
95  static_assert(static_cast<size_t>(AudioNode::NodeTypeEnd) == 20, "AudioNode::NodeTypeConstant is not 20 as expected");
 96 static_assert(static_cast<size_t>(AudioNode::NodeTypeStereo) == 20, "AudioNode::NodeTypeStereo is not 20 as expected");
 97 static_assert(static_cast<size_t>(AudioNode::NodeTypeEnd) == 21, "AudioNode::NodeTypeConstant is not 21 as expected");
9698
9799 ASSERT(static_cast<size_t>(enumerationValue) < WTF_ARRAY_LENGTH(values));
98100

Source/WebCore/Modules/webaudio/AudioNode.h

@@public:
9090 NodeTypeWaveShaper,
9191 NodeTypeBasicInspector,
9292 NodeTypeConstant,
 93 NodeTypeStereo,
9394 NodeTypeEnd
9495 };
9596

Source/WebCore/Modules/webaudio/BaseAudioContext.cpp

7474#include "PlatformMediaSessionManager.h"
7575#include "ScriptController.h"
7676#include "ScriptProcessorNode.h"
 77#include "StereoPannerNode.h"
 78#include "StereoPannerOptions.h"
7779#include "WaveShaperNode.h"
7880#include "WebKitAudioListener.h"
7981#include <JavaScriptCore/ScriptCallStack.h>

@@ExceptionOr<Ref<ConstantSourceNode>> BaseAudioContext::createConstantSource()
620622 return ConstantSourceNode::create(*this);
621623}
622624
 625ExceptionOr<Ref<StereoPannerNode>> BaseAudioContext::createStereoPanner()
 626{
 627 ALWAYS_LOG(LOGIDENTIFIER);
 628
 629 ASSERT(isMainThread());
 630 return StereoPannerNode::create(*this);
 631}
 632
623633void BaseAudioContext::notifyNodeFinishedProcessing(AudioNode* node)
624634{
625635 ASSERT(isAudioThread());

Source/WebCore/Modules/webaudio/BaseAudioContext.h

@@class PannerNode;
8080class PeriodicWave;
8181class ScriptProcessorNode;
8282class SecurityOrigin;
 83class StereoPannerNode;
8384class WaveShaperNode;
8485
8586template<typename IDLType> class DOMPromiseDeferred;

@@public:
162163 ExceptionOr<Ref<OscillatorNode>> createOscillator();
163164 ExceptionOr<Ref<PeriodicWave>> createPeriodicWave(Vector<float>&& real, Vector<float>&& imaginary, const PeriodicWaveConstraints& = { });
164165 ExceptionOr<Ref<ConstantSourceNode>> createConstantSource();
 166 ExceptionOr<Ref<StereoPannerNode>> createStereoPanner();
165167
166168 // When a source node has no more processing to do (has finished playing), then it tells the context to dereference it.
167169 void notifyNodeFinishedProcessing(AudioNode*);

Source/WebCore/Modules/webaudio/BaseAudioContext.idl

6565 [MayThrowException] OscillatorNode createOscillator();
6666 [MayThrowException] PeriodicWave createPeriodicWave(sequence<float> real, sequence<float> imag, optional PeriodicWaveOptions options);
6767 [MayThrowException] ConstantSourceNode createConstantSource();
 68 [MayThrowException] StereoPannerNode createStereoPanner();
6869
6970 // Channel splitting and merging
7071 [MayThrowException] ChannelSplitterNode createChannelSplitter(optional unsigned long numberOfOutputs = 6);

Source/WebCore/Modules/webaudio/StereoPannerNode.cpp

 1/*
 2 * Copyright 2014 The Chromium Authors. All rights reserved.
 3 * Copyright (C) 2020 Apple Inc. All rights reserved.
 4 *
 5 * Redistribution and use in source and binary forms, with or without
 6 * modification, are permitted provided that the following conditions
 7 * are met:
 8 * 1. Redistributions of source code must retain the above copyright
 9 * notice, this list of conditions and the following disclaimer.
 10 * 2. Redistributions in binary form must reproduce the above copyright
 11 * notice, this list of conditions and the following disclaimer in the
 12 * documentation and/or other materials provided with the distribution.
 13 *
 14 * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
 15 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
 16 * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
 17 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
 18 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 19 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 20 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 21 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 22 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 23 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
 24 * THE POSSIBILITY OF SUCH DAMAGE.
 25 */
 26
 27#include "config.h"
 28#include "StereoPannerNode.h"
 29
 30#if ENABLE(WEB_AUDIO)
 31
 32#include "AudioBus.h"
 33
 34namespace WebCore {
 35
 36WTF_MAKE_ISO_ALLOCATED_IMPL(StereoPannerNode);
 37
 38ExceptionOr<Ref<StereoPannerNode>> StereoPannerNode::create(BaseAudioContext& context, const StereoPannerOptions& options)
 39{
 40 if (context.isStopped())
 41 return Exception { InvalidStateError };
 42
 43 context.lazyInitialize();
 44
 45 auto stereo = adoptRef(*new StereoPannerNode(context, options.pan));
 46
 47 auto result = stereo->handleAudioNodeOptions(options, { 2, ChannelCountMode::ClampedMax, ChannelInterpretation::Speakers });
 48 if (result.hasException())
 49 return result.releaseException();
 50
 51 return stereo;
 52}
 53
 54StereoPannerNode::StereoPannerNode(BaseAudioContext& context, float pan)
 55 : AudioNode(context)
 56 , m_pan(AudioParam::create(context, "pan"_s, pan, -1, 1))
 57{
 58 setNodeType(NodeTypeStereo);
 59
 60 addInput(makeUnique<AudioNodeInput>(this));
 61 addOutput(makeUnique<AudioNodeOutput>(this, 2));
 62
 63 initialize();
 64}
 65
 66StereoPannerNode::~StereoPannerNode()
 67{
 68 uninitialize();
 69}
 70
 71void StereoPannerNode::process(size_t framesToProcess)
 72{
 73 AudioBus* destination = output(0)->bus();
 74
 75 if (!isInitialized() || !input(0)->isConnected() || !m_stereoPanner) {
 76 destination->zero();
 77 return;
 78 }
 79
 80 AudioBus* source = input(0)->bus();
 81 if (!source) {
 82 destination->zero();
 83 return;
 84 }
 85
 86 // FIXME: Fix once automation-rate is introduced. Some tests are failing because this
 87 // is called for both a-rate and k-rate, but should only be called on a-rate.
 88 if (m_pan->hasSampleAccurateValues()) {
 89 float* panValues = m_sampleAccurateValues.data();
 90 m_pan->calculateSampleAccurateValues(panValues, framesToProcess);
 91 m_stereoPanner->panWithSampleAccurateValues(source, destination, panValues, framesToProcess);
 92 return;
 93 }
 94
 95 float panValue = m_pan->value();
 96 m_stereoPanner->panToTargetValue(source, destination, panValue, framesToProcess);
 97}
 98
 99void StereoPannerNode::initialize()
 100{
 101 if (isInitialized())
 102 return;
 103
 104 m_stereoPanner = makeUnique<StereoPanner>();
 105 AudioNode::initialize();
 106}
 107
 108void StereoPannerNode::uninitialize()
 109{
 110 if (!isInitialized())
 111 return;
 112
 113 m_stereoPanner = nullptr;
 114 AudioNode::uninitialize();
 115}
 116
 117ExceptionOr<void> StereoPannerNode::setChannelCount(unsigned channelCount)
 118{
 119 if (channelCount > 2)
 120 return Exception { NotSupportedError, "StereoPannerNode's channelCount cannot be greater than 2."_s };
 121
 122 return AudioNode::setChannelCount(channelCount);
 123}
 124
 125ExceptionOr<void> StereoPannerNode::setChannelCountMode(ChannelCountMode mode)
 126{
 127 if (mode == ChannelCountMode::Max)
 128 return Exception { NotSupportedError, "StereoPannerNode's channelCountMode cannot be max."_s };
 129
 130 return AudioNode::setChannelCountMode(mode);
 131}
 132
 133} // namespace WebCore
 134
 135#endif // ENABLE(WEB_AUDIO)

Source/WebCore/Modules/webaudio/StereoPannerNode.h

 1/*
 2 * Copyright 2014 The Chromium Authors. All rights reserved.
 3 * Copyright (C) 2020 Apple Inc. All rights reserved.
 4 *
 5 * Redistribution and use in source and binary forms, with or without
 6 * modification, are permitted provided that the following conditions
 7 * are met:
 8 * 1. Redistributions of source code must retain the above copyright
 9 * notice, this list of conditions and the following disclaimer.
 10 * 2. Redistributions in binary form must reproduce the above copyright
 11 * notice, this list of conditions and the following disclaimer in the
 12 * documentation and/or other materials provided with the distribution.
 13 *
 14 * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
 15 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
 16 * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
 17 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
 18 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 19 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 20 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 21 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 22 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 23 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
 24 * THE POSSIBILITY OF SUCH DAMAGE.
 25 */
 26
 27#pragma once
 28
 29#if ENABLE(WEB_AUDIO)
 30
 31#include "AudioNode.h"
 32#include "AudioParam.h"
 33#include "StereoPanner.h"
 34#include "StereoPannerOptions.h"
 35
 36namespace WebCore {
 37
 38class AudioContext;
 39
 40class StereoPannerNode final : public AudioNode {
 41 WTF_MAKE_ISO_ALLOCATED(StereoPannerNode);
 42public:
 43 static ExceptionOr<Ref<StereoPannerNode>> create(BaseAudioContext&, const StereoPannerOptions& = { });
 44
 45 virtual ~StereoPannerNode();
 46
 47 AudioParam& pan() { return m_pan.get(); }
 48
 49private:
 50 StereoPannerNode(BaseAudioContext&, float pan);
 51
 52 // AudioNode
 53 void process(size_t framesToProcess) final;
 54 void reset() final { };
 55 void initialize() final;
 56 void uninitialize() final;
 57
 58 ExceptionOr<void> setChannelCount(unsigned) final;
 59 ExceptionOr<void> setChannelCountMode(ChannelCountMode) final;
 60
 61 double tailTime() const final { return 0; }
 62 double latencyTime() const final { return 0; }
 63
 64 Ref<AudioParam> m_pan;
 65
 66 std::unique_ptr<StereoPanner> m_stereoPanner;
 67
 68 AudioFloatArray m_sampleAccurateValues { AudioNode::ProcessingSizeInFrames };
 69};
 70
 71} // namespace WebCore
 72
 73#endif // ENABLE(WEB_AUDIO)

Source/WebCore/Modules/webaudio/StereoPannerNode.idl

 1/*
 2 * Copyright (C) 2020 Apple Inc. All rights reserved.
 3 *
 4 * Redistribution and use in source and binary forms, with or without
 5 * modification, are permitted provided that the following conditions
 6 * are met:
 7 * 1. Redistributions of source code must retain the above copyright
 8 * notice, this list of conditions and the following disclaimer.
 9 * 2. Redistributions in binary form must reproduce the above copyright
 10 * notice, this list of conditions and the following disclaimer in the
 11 * documentation and/or other materials provided with the distribution.
 12 *
 13 * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
 14 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
 15 * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
 16 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
 17 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 18 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 19 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 20 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 21 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 22 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
 23 * THE POSSIBILITY OF SUCH DAMAGE.
 24 */
 25
 26[
 27 Conditional=WEB_AUDIO,
 28 JSGenerateToJSObject,
 29 EnabledBySetting=ModernUnprefixedWebAudio
 30] interface StereoPannerNode : AudioNode {
 31 [MayThrowException] constructor (BaseAudioContext context, optional StereoPannerOptions options);
 32 readonly attribute AudioParam pan;
 33};

Source/WebCore/Modules/webaudio/StereoPannerOptions.h

 1/*
 2 * Copyright (C) 2020 Apple Inc. All rights reserved.
 3 *
 4 * Redistribution and use in source and binary forms, with or without
 5 * modification, are permitted provided that the following conditions
 6 * are met:
 7 * 1. Redistributions of source code must retain the above copyright
 8 * notice, this list of conditions and the following disclaimer.
 9 * 2. Redistributions in binary form must reproduce the above copyright
 10 * notice, this list of conditions and the following disclaimer in the
 11 * documentation and/or other materials provided with the distribution.
 12 *
 13 * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
 14 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
 15 * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
 16 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
 17 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 18 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 19 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 20 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 21 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 22 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
 23 * THE POSSIBILITY OF SUCH DAMAGE.
 24 */
 25
 26#pragma once
 27
 28#if ENABLE(WEB_AUDIO)
 29
 30#include "AudioNodeOptions.h"
 31
 32namespace WebCore {
 33
 34struct StereoPannerOptions : AudioNodeOptions {
 35 float pan { 0 };
 36};
 37
 38} // namespace WebCore
 39
 40#endif // ENABLE(WEB_AUDIO)

Source/WebCore/Modules/webaudio/StereoPannerOptions.idl

 1/*
 2 * Copyright (C) 2020 Apple Inc. All rights reserved.
 3 *
 4 * Redistribution and use in source and binary forms, with or without
 5 * modification, are permitted provided that the following conditions
 6 * are met:
 7 * 1. Redistributions of source code must retain the above copyright
 8 * notice, this list of conditions and the following disclaimer.
 9 * 2. Redistributions in binary form must reproduce the above copyright
 10 * notice, this list of conditions and the following disclaimer in the
 11 * documentation and/or other materials provided with the distribution.
 12 *
 13 * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
 14 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
 15 * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
 16 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
 17 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 18 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 19 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 20 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 21 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 22 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
 23 * THE POSSIBILITY OF SUCH DAMAGE.
 24 */
 25
 26[
 27 Conditional=WEB_AUDIO,
 28] dictionary StereoPannerOptions : AudioNodeOptions {
 29 float pan = 0;
 30};

Source/WebCore/Sources.txt

@@Modules/webaudio/PannerNode.cpp
233233Modules/webaudio/PeriodicWave.cpp
234234Modules/webaudio/RealtimeAnalyser.cpp
235235Modules/webaudio/ScriptProcessorNode.cpp
 236Modules/webaudio/StereoPannerNode.cpp
236237Modules/webaudio/WaveShaperDSPKernel.cpp
237238Modules/webaudio/WaveShaperNode.cpp
238239Modules/webaudio/WaveShaperProcessor.cpp

@@platform/audio/ReverbConvolver.cpp
18071808platform/audio/ReverbConvolverStage.cpp
18081809platform/audio/ReverbInputBuffer.cpp
18091810platform/audio/SincResampler.cpp
 1811platform/audio/StereoPanner.cpp
18101812platform/audio/UpSampler.cpp
18111813platform/audio/VectorMath.cpp
18121814platform/audio/ZeroPole.cpp

@@JSSpeechSynthesis.cpp
34583460JSSpeechSynthesisEvent.cpp
34593461JSSpeechSynthesisUtterance.cpp
34603462JSSpeechSynthesisVoice.cpp
 3463JSStereoPannerNode.cpp
 3464JSStereoPannerOptions.cpp
34613465JSStaticRange.cpp
34623466JSStorage.cpp
34633467JSStorageErrorCallback.cpp

Source/WebCore/WebCore.xcodeproj/project.pbxproj

50945094 E7C8E13B24E2FE7E0027A27F /* ConstantSourceNode.h in Headers */ = {isa = PBXBuildFile; fileRef = E7C8E13824E2FE650027A27F /* ConstantSourceNode.h */; };
50955095 E7CF84A924C6461C00B06B90 /* OfflineAudioContextOptions.h in Headers */ = {isa = PBXBuildFile; fileRef = E7CF84A524C635F400B06B90 /* OfflineAudioContextOptions.h */; };
50965096 E7E0357224D4E196008DFEFB /* AnalyserOptions.h in Headers */ = {isa = PBXBuildFile; fileRef = E7E0357124D4E191008DFEFB /* AnalyserOptions.h */; };
 5097 E7FBE7C224EB2FB000A18E62 /* StereoPannerNode.h in Headers */ = {isa = PBXBuildFile; fileRef = E7FBE7C124EB2FAB00A18E62 /* StereoPannerNode.h */; };
 5098 E7FBE7C324EB2FB600A18E62 /* StereoPannerOptions.h in Headers */ = {isa = PBXBuildFile; fileRef = E7FBE7C024EB2FAB00A18E62 /* StereoPannerOptions.h */; };
50975099 EBE5B226245A26EF003A5A88 /* SQLiteStatementAutoResetScope.h in Headers */ = {isa = PBXBuildFile; fileRef = EBE5B224245A26EE003A5A88 /* SQLiteStatementAutoResetScope.h */; settings = {ATTRIBUTES = (Private, ); }; };
50985100 EBF5121C1696496C0056BD25 /* JSTypeConversions.cpp in Sources */ = {isa = PBXBuildFile; fileRef = EBF5121A1696496C0056BD25 /* JSTypeConversions.cpp */; };
50995101 EBF5121D1696496C0056BD25 /* JSTypeConversions.h in Headers */ = {isa = PBXBuildFile; fileRef = EBF5121B1696496C0056BD25 /* JSTypeConversions.h */; };

1595915961 E7E0355924D346DF008DFEFB /* AudioBufferOptions.idl */ = {isa = PBXFileReference; lastKnownFileType = text; path = AudioBufferOptions.idl; sourceTree = "<group>"; };
1596015962 E7E0356F24D4E190008DFEFB /* AnalyserOptions.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = AnalyserOptions.idl; sourceTree = "<group>"; };
1596115963 E7E0357124D4E191008DFEFB /* AnalyserOptions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AnalyserOptions.h; sourceTree = "<group>"; };
 15964 E7FBE7BC24EB2FA900A18E62 /* StereoPannerNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = StereoPannerNode.cpp; sourceTree = "<group>"; };
 15965 E7FBE7BE24EB2FAA00A18E62 /* StereoPannerOptions.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = StereoPannerOptions.idl; sourceTree = "<group>"; };
 15966 E7FBE7BF24EB2FAA00A18E62 /* StereoPannerNode.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = StereoPannerNode.idl; sourceTree = "<group>"; };
 15967 E7FBE7C024EB2FAB00A18E62 /* StereoPannerOptions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = StereoPannerOptions.h; sourceTree = "<group>"; };
 15968 E7FBE7C124EB2FAB00A18E62 /* StereoPannerNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = StereoPannerNode.h; sourceTree = "<group>"; };
 15969 E7FBE7C424EC36F300A18E62 /* StereoPanner.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = StereoPanner.h; sourceTree = "<group>"; };
 15970 E7FBE7C524EC36F300A18E62 /* StereoPanner.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = StereoPanner.cpp; sourceTree = "<group>"; };
1596215971 EB081CD81696084400553730 /* TypeConversions.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = TypeConversions.h; sourceTree = "<group>"; };
1596315972 EB081CD91696084400553730 /* TypeConversions.idl */ = {isa = PBXFileReference; lastKnownFileType = text; path = TypeConversions.idl; sourceTree = "<group>"; };
1596415973 EBE5B224245A26EE003A5A88 /* SQLiteStatementAutoResetScope.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SQLiteStatementAutoResetScope.h; sourceTree = "<group>"; };

2972129730 FD315FEB12B0267600C1A359 /* ScriptProcessorNode.cpp */,
2972229731 FD315FEC12B0267600C1A359 /* ScriptProcessorNode.h */,
2972329732 FD315FED12B0267600C1A359 /* ScriptProcessorNode.idl */,
 29733 E7FBE7BC24EB2FA900A18E62 /* StereoPannerNode.cpp */,
 29734 E7FBE7C124EB2FAB00A18E62 /* StereoPannerNode.h */,
 29735 E7FBE7BF24EB2FAA00A18E62 /* StereoPannerNode.idl */,
 29736 E7FBE7C024EB2FAB00A18E62 /* StereoPannerOptions.h */,
 29737 E7FBE7BE24EB2FAA00A18E62 /* StereoPannerOptions.idl */,
2972429738 FD7F298A13D4C0CB00AD9535 /* WaveShaperDSPKernel.cpp */,
2972529739 FD7F298B13D4C0CB00AD9535 /* WaveShaperDSPKernel.h */,
2972629740 FD7F298C13D4C0CB00AD9535 /* WaveShaperNode.cpp */,

2983529849 FD31607712B026F700C1A359 /* ReverbInputBuffer.h */,
2983629850 FD00D7A214A3F61900734011 /* SincResampler.cpp */,
2983729851 FD00D7A314A3F61900734011 /* SincResampler.h */,
 29852 E7FBE7C524EC36F300A18E62 /* StereoPanner.cpp */,
 29853 E7FBE7C424EC36F300A18E62 /* StereoPanner.h */,
2983829854 FD1762DD176686D900D836A8 /* UpSampler.cpp */,
2983929855 FD1762DE176686D900D836A8 /* UpSampler.h */,
2984029856 FD31607812B026F700C1A359 /* VectorMath.cpp */,

3359133607 F433E9031DBBDBA200EF0D14 /* StaticPasteboard.h in Headers */,
3359233608 F44EBBD91DB5D21400277334 /* StaticRange.h in Headers */,
3359333609 A5AFB350115151A700B045CB /* StepRange.h in Headers */,
 33610 E7FBE7C224EB2FB000A18E62 /* StereoPannerNode.h in Headers */,
 33611 E7FBE7C324EB2FB600A18E62 /* StereoPannerOptions.h in Headers */,
3359433612 1AC2D845171734A100652FC0 /* Storage.h in Headers */,
3359533613 51BE37E00DAEE00E001085FC /* StorageArea.h in Headers */,
3359633614 51E0BABB0DA5547100A9E417 /* StorageEvent.h in Headers */,

Source/WebCore/bindings/js/WebCoreBuiltinNames.h

@@namespace WebCore {
231231 macro(ServiceWorkerRegistration) \
232232 macro(ShadowRoot) \
233233 macro(StaticRange) \
 234 macro(StereoPannerNode) \
234235 macro(StylePropertyMapReadOnly) \
235236 macro(StylePropertyMap) \
236237 macro(TextTrackCue) \

Source/WebCore/platform/audio/StereoPanner.cpp

 1/*
 2 * Copyright 2014 The Chromium Authors. All rights reserved.
 3 * Copyright (C) 2020 Apple Inc. All rights reserved.
 4 *
 5 * Redistribution and use in source and binary forms, with or without
 6 * modification, are permitted provided that the following conditions
 7 * are met:
 8 * 1. Redistributions of source code must retain the above copyright
 9 * notice, this list of conditions and the following disclaimer.
 10 * 2. Redistributions in binary form must reproduce the above copyright
 11 * notice, this list of conditions and the following disclaimer in the
 12 * documentation and/or other materials provided with the distribution.
 13 *
 14 * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
 15 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
 16 * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
 17 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
 18 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 19 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 20 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 21 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 22 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 23 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
 24 * THE POSSIBILITY OF SUCH DAMAGE.
 25 */
 26
 27#include "config.h"
 28#include "StereoPanner.h"
 29
 30#if ENABLE(WEB_AUDIO)
 31
 32#include "AudioBus.h"
 33#include "AudioUtilities.h"
 34#include <wtf/MathExtras.h>
 35
 36namespace WebCore {
 37
 38void StereoPanner::panWithSampleAccurateValues(const AudioBus* inputBus, AudioBus* outputBus, const float* panValues, size_t framesToProcess)
 39{
 40 bool isInputSafe = inputBus && (inputBus->numberOfChannels() == 1 || inputBus->numberOfChannels() == 2) && framesToProcess <= inputBus->length();
 41 ASSERT(isInputSafe);
 42 if (!isInputSafe)
 43 return;
 44
 45 unsigned numberOfInputChannels = inputBus->numberOfChannels();
 46
 47 bool isOutputSafe = outputBus && outputBus->numberOfChannels() == 2 && framesToProcess <= outputBus->length();
 48 ASSERT(isOutputSafe);
 49 if (!isOutputSafe)
 50 return;
 51
 52 const float* sourceL = inputBus->channel(0)->data();
 53 const float* sourceR = numberOfInputChannels > 1 ? inputBus->channel(1)->data() : sourceL;
 54 float* destinationL = outputBus->channelByType(AudioBus::ChannelLeft)->mutableData();
 55 float* destinationR = outputBus->channelByType(AudioBus::ChannelRight)->mutableData();
 56
 57 if (!sourceL || !sourceR || !destinationL || !destinationR)
 58 return;
 59
 60 double gainL;
 61 double gainR;
 62 double panRadian;
 63
 64 int n = framesToProcess;
 65
 66 // Handles mono source case first, then stereo source case.
 67 if (numberOfInputChannels == 1) {
 68 while (n--) {
 69 float inputL = *sourceL++;
 70 double pan = clampTo(*panValues++, -1.0, 1.0);
 71 // Pan from left to right [-1; 1] will be normalized as [0; 1].
 72 panRadian = (pan * 0.5 + 0.5) * piOverTwoDouble;
 73 gainL = cos(panRadian);
 74 gainR = sin(panRadian);
 75 *destinationL++ = static_cast<float>(inputL * gainL);
 76 *destinationR++ = static_cast<float>(inputL * gainR);
 77 }
 78 } else {
 79 while (n--) {
 80 float inputL = *sourceL++;
 81 float inputR = *sourceR++;
 82 double pan = clampTo(*panValues++, -1.0, 1.0);
 83 // Normalize [-1; 0] to [0; 1]. Do nothing when [0; 1].
 84 panRadian = (pan <= 0 ? pan + 1 : pan) * piOverTwoDouble;
 85 gainL = cos(panRadian);
 86 gainR = sin(panRadian);
 87 if (pan <= 0) {
 88 *destinationL++ = static_cast<float>(inputL + inputR * gainL);
 89 *destinationR++ = static_cast<float>(inputR * gainR);
 90 } else {
 91 *destinationL++ = static_cast<float>(inputL * gainL);
 92 *destinationR++ = static_cast<float>(inputR + inputL * gainR);
 93 }
 94 }
 95 }
 96}
 97
 98void StereoPanner::panToTargetValue(const AudioBus* inputBus, AudioBus* outputBus, float panValue, size_t framesToProcess)
 99{
 100 bool isInputSafe = inputBus && (inputBus->numberOfChannels() == 1 || inputBus->numberOfChannels() == 2) && framesToProcess <= inputBus->length();
 101 ASSERT(isInputSafe);
 102 if (!isInputSafe)
 103 return;
 104
 105 unsigned numberOfInputChannels = inputBus->numberOfChannels();
 106
 107 bool isOutputSafe = outputBus && outputBus->numberOfChannels() == 2 && framesToProcess <= outputBus->length();
 108 ASSERT(isOutputSafe);
 109 if (!isOutputSafe)
 110 return;
 111
 112 const float* sourceL = inputBus->channel(0)->data();
 113 const float* sourceR = numberOfInputChannels > 1 ? inputBus->channel(1)->data() : sourceL;
 114 float* destinationL = outputBus->channelByType(AudioBus::ChannelLeft)->mutableData();
 115 float* destinationR = outputBus->channelByType(AudioBus::ChannelRight)->mutableData();
 116
 117 if (!sourceL || !sourceR || !destinationL || !destinationR)
 118 return;
 119
 120 float targetPan = clampTo(panValue, -1.0, 1.0);
 121
 122 int n = framesToProcess;
 123
 124 if (numberOfInputChannels == 1) {
 125 double panRadian = (targetPan * 0.5 + 0.5) * piOverTwoDouble;
 126
 127 double gainL = cos(panRadian);
 128 double gainR = sin(panRadian);
 129
 130 while (n--) {
 131 float inputL = *sourceL++;
 132 *destinationL++ = static_cast<float>(inputL * gainL);
 133 *destinationR++ = static_cast<float>(inputL * gainR);
 134 }
 135 } else {
 136 double panRadian = (targetPan <= 0 ? targetPan + 1 : targetPan) * piOverTwoDouble;
 137
 138 double gainL = cos(panRadian);
 139 double gainR = sin(panRadian);
 140
 141 while (n--) {
 142 float inputL = *sourceL++;
 143 float inputR = *sourceR++;
 144 if (targetPan <= 0) {
 145 *destinationL++ = static_cast<float>(inputL + inputR * gainL);
 146 *destinationR++ = static_cast<float>(inputR * gainR);
 147 } else {
 148 *destinationL++ = static_cast<float>(inputL * gainL);
 149 *destinationR++ = static_cast<float>(inputR + inputL * gainR);
 150 }
 151 }
 152 }
 153}
 154
 155} // namespace WebCore
 156
 157#endif // ENABLE(WEB_AUDIO)

Source/WebCore/platform/audio/StereoPanner.h

 1/*
 2 * Copyright 2014 The Chromium Authors. All rights reserved.
 3 * Copyright (C) 2020 Apple Inc. All rights reserved.
 4 *
 5 * Redistribution and use in source and binary forms, with or without
 6 * modification, are permitted provided that the following conditions
 7 * are met:
 8 * 1. Redistributions of source code must retain the above copyright
 9 * notice, this list of conditions and the following disclaimer.
 10 * 2. Redistributions in binary form must reproduce the above copyright
 11 * notice, this list of conditions and the following disclaimer in the
 12 * documentation and/or other materials provided with the distribution.
 13 *
 14 * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
 15 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
 16 * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
 17 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
 18 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 19 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 20 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 21 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 22 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 23 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
 24 * THE POSSIBILITY OF SUCH DAMAGE.
 25 */
 26
 27#pragma once
 28
 29#include <memory>
 30
 31namespace WebCore {
 32
 33class AudioBus;
 34
 35class StereoPanner {
 36 WTF_MAKE_FAST_ALLOCATED;
 37public:
 38 void panWithSampleAccurateValues(const AudioBus* inputBus, AudioBus* outputBus, const float* panValues, size_t framesToProcess);
 39
 40 void panToTargetValue(const AudioBus* inputBus, AudioBus* outputBus, float panValue, size_t framesToProcess);
 41};
 42
 43} // namespace WebCore

Source/WebCore/platform/graphics/cocoa/SourceBufferParserWebM.cpp

2929#if ENABLE(MEDIA_SOURCE)
3030
3131#include "AudioTrackPrivateWebM.h"
 32#include "ContentType.h"
3233#include "CoreVideoSoftLink.h"
3334#include "InbandTextTrackPrivate.h"
3435#include "MediaDescription.h"

@@WTF_WEAK_LINK_FORCE_IMPORT(webm::swap);
5253
5354namespace WebCore {
5455
 56// FIXME: Remove this once kCMVideoCodecType_VP9 is added to CMFormatDescription.h
 57constexpr CMVideoCodecType kCMVideoCodecType_VP9 { 'vp09' };
 58
5559using namespace PAL;
5660
5761static bool isWebmParserAvailable()

LayoutTests/imported/w3c/ChangeLog

 12020-08-19 Clark Wang <clark_wang@apple.com>
 2
 3 Introduce StereoPannerNode Interface
 4 https://bugs.webkit.org/show_bug.cgi?id=215518
 5
 6 Reviewed by Darin Adler.
 7
 8 Re-baselined existing tests. Some now fail due to missing automation rate.
 9
 10 * web-platform-tests/webaudio/idlharness.https.window-expected.txt:
 11 * web-platform-tests/webaudio/the-audio-api/the-audionode-interface/audionode-connect-method-chaining-expected.txt:
 12 * web-platform-tests/webaudio/the-audio-api/the-audioparam-interface/automation-rate-expected.txt:
 13 * web-platform-tests/webaudio/the-audio-api/the-audioparam-interface/k-rate-connections-expected.txt:
 14 * web-platform-tests/webaudio/the-audio-api/the-audioparam-interface/k-rate-stereo-panner-expected.txt:
 15 * web-platform-tests/webaudio/the-audio-api/the-stereopanner-interface/ctor-stereopanner-expected.txt:
 16 * web-platform-tests/webaudio/the-audio-api/the-stereopanner-interface/no-dezippering-expected.txt:
 17 * web-platform-tests/webaudio/the-audio-api/the-stereopanner-interface/stereopannernode-basic-expected.txt:
 18 * web-platform-tests/webaudio/the-audio-api/the-stereopanner-interface/stereopannernode-panning-expected.txt:
 19
1202020-08-18 Chris Dumez <cdumez@apple.com>
221
322 Unreviewed, rebaseline webaudio WPT tests that are marked as flaky.

LayoutTests/TestExpectations

@@imported/w3c/web-platform-tests/webaudio/the-audio-api/the-audioparam-interface/
346346imported/w3c/web-platform-tests/webaudio/the-audio-api/the-convolvernode-interface/realtime-conv.html [ Pass Failure ]
347347imported/w3c/web-platform-tests/webaudio/the-audio-api/the-audioparam-interface/k-rate-dynamics-compressor-connections.html [ Pass Failure ]
348348imported/w3c/web-platform-tests/webaudio/the-audio-api/the-constantsourcenode-interface/constant-source-output.html [ Pass Failure ]
 349imported/w3c/web-platform-tests/webaudio/the-audio-api/the-audioparam-interface/k-rate-stereo-panner.html [ Pass Failure ]
 350imported/w3c/web-platform-tests/webaudio/the-audio-api/the-stereopanner-interface/no-dezippering.html [ Pass Failure ]
349351
350352webkit.org/b/176929 imported/w3c/web-platform-tests/html/semantics/embedded-content/media-elements/ready-states/autoplay-with-slow-text-tracks.html [ Pass Failure ]
351353

LayoutTests/imported/w3c/web-platform-tests/webaudio/idlharness.https.window-expected.txt

@@PASS BaseAudioContext interface: operation createOscillator()
3838PASS BaseAudioContext interface: operation createPanner()
3939PASS BaseAudioContext interface: operation createPeriodicWave(sequence<float>, sequence<float>, optional PeriodicWaveConstraints)
4040PASS BaseAudioContext interface: operation createScriptProcessor(optional unsigned long, optional unsigned long, optional unsigned long)
41 FAIL BaseAudioContext interface: operation createStereoPanner() assert_own_property: interface prototype object missing non-static operation expected property "createStereoPanner" missing
 41PASS BaseAudioContext interface: operation createStereoPanner()
4242PASS BaseAudioContext interface: operation createWaveShaper()
4343PASS BaseAudioContext interface: operation decodeAudioData(ArrayBuffer, optional DecodeSuccessCallback?, optional DecodeErrorCallback?)
4444PASS AudioContext interface: existence and properties of interface object

@@PASS BaseAudioContext interface: context must inherit property "createPeriodicWa
102102PASS BaseAudioContext interface: calling createPeriodicWave(sequence<float>, sequence<float>, optional PeriodicWaveConstraints) on context with too few arguments must throw TypeError
103103PASS BaseAudioContext interface: context must inherit property "createScriptProcessor(optional unsigned long, optional unsigned long, optional unsigned long)" with the proper type
104104PASS BaseAudioContext interface: calling createScriptProcessor(optional unsigned long, optional unsigned long, optional unsigned long) on context with too few arguments must throw TypeError
105 FAIL BaseAudioContext interface: context must inherit property "createStereoPanner()" with the proper type assert_inherits: property "createStereoPanner" not found in prototype chain
 105PASS BaseAudioContext interface: context must inherit property "createStereoPanner()" with the proper type
106106PASS BaseAudioContext interface: context must inherit property "createWaveShaper()" with the proper type
107107PASS BaseAudioContext interface: context must inherit property "decodeAudioData(ArrayBuffer, optional DecodeSuccessCallback?, optional DecodeErrorCallback?)" with the proper type
108108PASS BaseAudioContext interface: calling decodeAudioData(ArrayBuffer, optional DecodeSuccessCallback?, optional DecodeErrorCallback?) on context with too few arguments must throw TypeError

@@PASS BaseAudioContext interface: new OfflineAudioContext(1, 1, sample_rate) must
155155PASS BaseAudioContext interface: calling createPeriodicWave(sequence<float>, sequence<float>, optional PeriodicWaveConstraints) on new OfflineAudioContext(1, 1, sample_rate) with too few arguments must throw TypeError
156156PASS BaseAudioContext interface: new OfflineAudioContext(1, 1, sample_rate) must inherit property "createScriptProcessor(optional unsigned long, optional unsigned long, optional unsigned long)" with the proper type
157157PASS BaseAudioContext interface: calling createScriptProcessor(optional unsigned long, optional unsigned long, optional unsigned long) on new OfflineAudioContext(1, 1, sample_rate) with too few arguments must throw TypeError
158 FAIL BaseAudioContext interface: new OfflineAudioContext(1, 1, sample_rate) must inherit property "createStereoPanner()" with the proper type assert_inherits: property "createStereoPanner" not found in prototype chain
 158PASS BaseAudioContext interface: new OfflineAudioContext(1, 1, sample_rate) must inherit property "createStereoPanner()" with the proper type
159159PASS BaseAudioContext interface: new OfflineAudioContext(1, 1, sample_rate) must inherit property "createWaveShaper()" with the proper type
160160PASS BaseAudioContext interface: new OfflineAudioContext(1, 1, sample_rate) must inherit property "decodeAudioData(ArrayBuffer, optional DecodeSuccessCallback?, optional DecodeErrorCallback?)" with the proper type
161161PASS BaseAudioContext interface: calling decodeAudioData(ArrayBuffer, optional DecodeSuccessCallback?, optional DecodeErrorCallback?) on new OfflineAudioContext(1, 1, sample_rate) with too few arguments must throw TypeError

@@PASS AudioNode interface: context.createScriptProcessor() must inherit property
10101010PASS AudioNode interface: context.createScriptProcessor() must inherit property "channelCount" with the proper type
10111011PASS AudioNode interface: context.createScriptProcessor() must inherit property "channelCountMode" with the proper type
10121012PASS AudioNode interface: context.createScriptProcessor() must inherit property "channelInterpretation" with the proper type
1013 FAIL StereoPannerNode interface: existence and properties of interface object assert_own_property: self does not have own property "StereoPannerNode" expected property "StereoPannerNode" missing
1014 FAIL StereoPannerNode interface object length assert_own_property: self does not have own property "StereoPannerNode" expected property "StereoPannerNode" missing
1015 FAIL StereoPannerNode interface object name assert_own_property: self does not have own property "StereoPannerNode" expected property "StereoPannerNode" missing
1016 FAIL StereoPannerNode interface: existence and properties of interface prototype object assert_own_property: self does not have own property "StereoPannerNode" expected property "StereoPannerNode" missing
1017 FAIL StereoPannerNode interface: existence and properties of interface prototype object's "constructor" property assert_own_property: self does not have own property "StereoPannerNode" expected property "StereoPannerNode" missing
1018 FAIL StereoPannerNode interface: existence and properties of interface prototype object's @@unscopables property assert_own_property: self does not have own property "StereoPannerNode" expected property "StereoPannerNode" missing
1019 FAIL StereoPannerNode interface: attribute pan assert_own_property: self does not have own property "StereoPannerNode" expected property "StereoPannerNode" missing
1020 FAIL StereoPannerNode must be primary interface of new StereoPannerNode(context) assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1021 FAIL Stringification of new StereoPannerNode(context) assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1022 FAIL StereoPannerNode interface: new StereoPannerNode(context) must inherit property "pan" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1023 FAIL AudioNode interface: new StereoPannerNode(context) must inherit property "connect(AudioNode, optional unsigned long, optional unsigned long)" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1024 FAIL AudioNode interface: calling connect(AudioNode, optional unsigned long, optional unsigned long) on new StereoPannerNode(context) with too few arguments must throw TypeError assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1025 FAIL AudioNode interface: new StereoPannerNode(context) must inherit property "connect(AudioParam, optional unsigned long)" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1026 FAIL AudioNode interface: calling connect(AudioParam, optional unsigned long) on new StereoPannerNode(context) with too few arguments must throw TypeError assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1027 FAIL AudioNode interface: new StereoPannerNode(context) must inherit property "disconnect()" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1028 FAIL AudioNode interface: new StereoPannerNode(context) must inherit property "disconnect(unsigned long)" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1029 FAIL AudioNode interface: calling disconnect(unsigned long) on new StereoPannerNode(context) with too few arguments must throw TypeError assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1030 FAIL AudioNode interface: new StereoPannerNode(context) must inherit property "disconnect(AudioNode)" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1031 FAIL AudioNode interface: calling disconnect(AudioNode) on new StereoPannerNode(context) with too few arguments must throw TypeError assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1032 FAIL AudioNode interface: new StereoPannerNode(context) must inherit property "disconnect(AudioNode, unsigned long)" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1033 FAIL AudioNode interface: calling disconnect(AudioNode, unsigned long) on new StereoPannerNode(context) with too few arguments must throw TypeError assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1034 FAIL AudioNode interface: new StereoPannerNode(context) must inherit property "disconnect(AudioNode, unsigned long, unsigned long)" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1035 FAIL AudioNode interface: calling disconnect(AudioNode, unsigned long, unsigned long) on new StereoPannerNode(context) with too few arguments must throw TypeError assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1036 FAIL AudioNode interface: new StereoPannerNode(context) must inherit property "disconnect(AudioParam)" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1037 FAIL AudioNode interface: calling disconnect(AudioParam) on new StereoPannerNode(context) with too few arguments must throw TypeError assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1038 FAIL AudioNode interface: new StereoPannerNode(context) must inherit property "disconnect(AudioParam, unsigned long)" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1039 FAIL AudioNode interface: calling disconnect(AudioParam, unsigned long) on new StereoPannerNode(context) with too few arguments must throw TypeError assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1040 FAIL AudioNode interface: new StereoPannerNode(context) must inherit property "context" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1041 FAIL AudioNode interface: new StereoPannerNode(context) must inherit property "numberOfInputs" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1042 FAIL AudioNode interface: new StereoPannerNode(context) must inherit property "numberOfOutputs" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1043 FAIL AudioNode interface: new StereoPannerNode(context) must inherit property "channelCount" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1044 FAIL AudioNode interface: new StereoPannerNode(context) must inherit property "channelCountMode" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
1045 FAIL AudioNode interface: new StereoPannerNode(context) must inherit property "channelInterpretation" with the proper type assert_equals: Unexpected exception when evaluating object expected null but got object "ReferenceError: Can't find variable: StereoPannerNode"
 1013PASS StereoPannerNode interface: existence and properties of interface object
 1014PASS StereoPannerNode interface object length
 1015PASS StereoPannerNode interface object name
 1016PASS StereoPannerNode interface: existence and properties of interface prototype object
 1017PASS StereoPannerNode interface: existence and properties of interface prototype object's "constructor" property
 1018PASS StereoPannerNode interface: existence and properties of interface prototype object's @@unscopables property
 1019PASS StereoPannerNode interface: attribute pan
 1020PASS StereoPannerNode must be primary interface of new StereoPannerNode(context)
 1021PASS Stringification of new StereoPannerNode(context)
 1022PASS StereoPannerNode interface: new StereoPannerNode(context) must inherit property "pan" with the proper type
 1023PASS AudioNode interface: new StereoPannerNode(context) must inherit property "connect(AudioNode, optional unsigned long, optional unsigned long)" with the proper type
 1024PASS AudioNode interface: calling connect(AudioNode, optional unsigned long, optional unsigned long) on new StereoPannerNode(context) with too few arguments must throw TypeError
 1025PASS AudioNode interface: new StereoPannerNode(context) must inherit property "connect(AudioParam, optional unsigned long)" with the proper type
 1026PASS AudioNode interface: calling connect(AudioParam, optional unsigned long) on new StereoPannerNode(context) with too few arguments must throw TypeError
 1027PASS AudioNode interface: new StereoPannerNode(context) must inherit property "disconnect()" with the proper type
 1028PASS AudioNode interface: new StereoPannerNode(context) must inherit property "disconnect(unsigned long)" with the proper type
 1029PASS AudioNode interface: calling disconnect(unsigned long) on new StereoPannerNode(context) with too few arguments must throw TypeError
 1030PASS AudioNode interface: new StereoPannerNode(context) must inherit property "disconnect(AudioNode)" with the proper type
 1031PASS AudioNode interface: calling disconnect(AudioNode) on new StereoPannerNode(context) with too few arguments must throw TypeError
 1032PASS AudioNode interface: new StereoPannerNode(context) must inherit property "disconnect(AudioNode, unsigned long)" with the proper type
 1033PASS AudioNode interface: calling disconnect(AudioNode, unsigned long) on new StereoPannerNode(context) with too few arguments must throw TypeError
 1034PASS AudioNode interface: new StereoPannerNode(context) must inherit property "disconnect(AudioNode, unsigned long, unsigned long)" with the proper type
 1035PASS AudioNode interface: calling disconnect(AudioNode, unsigned long, unsigned long) on new StereoPannerNode(context) with too few arguments must throw TypeError
 1036PASS AudioNode interface: new StereoPannerNode(context) must inherit property "disconnect(AudioParam)" with the proper type
 1037PASS AudioNode interface: calling disconnect(AudioParam) on new StereoPannerNode(context) with too few arguments must throw TypeError
 1038PASS AudioNode interface: new StereoPannerNode(context) must inherit property "disconnect(AudioParam, unsigned long)" with the proper type
 1039PASS AudioNode interface: calling disconnect(AudioParam, unsigned long) on new StereoPannerNode(context) with too few arguments must throw TypeError
 1040PASS AudioNode interface: new StereoPannerNode(context) must inherit property "context" with the proper type
 1041PASS AudioNode interface: new StereoPannerNode(context) must inherit property "numberOfInputs" with the proper type
 1042PASS AudioNode interface: new StereoPannerNode(context) must inherit property "numberOfOutputs" with the proper type
 1043PASS AudioNode interface: new StereoPannerNode(context) must inherit property "channelCount" with the proper type
 1044PASS AudioNode interface: new StereoPannerNode(context) must inherit property "channelCountMode" with the proper type
 1045PASS AudioNode interface: new StereoPannerNode(context) must inherit property "channelInterpretation" with the proper type
10461046PASS WaveShaperNode interface: existence and properties of interface object
10471047PASS WaveShaperNode interface object length
10481048PASS WaveShaperNode interface object name

LayoutTests/imported/w3c/web-platform-tests/webaudio/the-audio-api/the-audionode-interface/audionode-connect-method-chaining-expected.txt

11
22PASS # AUDIT TASK RUNNER STARTED.
3 FAIL Executing "from-dictionary" promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'context['create' + options.name].apply')"
 3PASS Executing "from-dictionary"
44PASS Executing "media-group"
55PASS Executing "invalid-operation"
66PASS Executing "verification"

@@PASS The return value of PannerNode.connect(ChannelMergerNode, 0, 1) matches t
4242PASS The return value of ScriptProcessorNode.connect(GainNode) matches the destination GainNode is equal to true.
4343PASS The return value of ScriptProcessorNode.connect(BiquadFilterNode, 0) matches the destination BiquadFilterNode is equal to true.
4444PASS The return value of ScriptProcessorNode.connect(ChannelMergerNode, 0, 1) matches the destination ChannelMergerNode is equal to true.
 45PASS The return value of StereoPannerNode.connect(GainNode) matches the destination GainNode is equal to true.
 46PASS The return value of StereoPannerNode.connect(BiquadFilterNode, 0) matches the destination BiquadFilterNode is equal to true.
 47PASS The return value of StereoPannerNode.connect(ChannelMergerNode, 0, 1) matches the destination ChannelMergerNode is equal to true.
 48PASS The return value of WaveShaperNode.connect(GainNode) matches the destination GainNode is equal to true.
 49PASS The return value of WaveShaperNode.connect(BiquadFilterNode, 0) matches the destination BiquadFilterNode is equal to true.
 50PASS The return value of WaveShaperNode.connect(ChannelMergerNode, 0, 1) matches the destination ChannelMergerNode is equal to true.
 51PASS < [from-dictionary] All assertions passed. (total 42 assertions)
4552PASS > [media-group]
4653PASS The return value of MediaElementAudioSourceNode.connect(GainNode) matches the destination GainNode is equal to true.
4754PASS The return value of MediaElementAudioSourceNode.connect(BiquadFilterNode, 0) matches the destination BiquadFilterNode is equal to true.

LayoutTests/imported/w3c/web-platform-tests/webaudio/the-audio-api/the-audioparam-interface/automation-rate-expected.txt

@@PASS Executing "DynamicsCompressorNode"
88PASS Executing "GainNode"
99PASS Executing "OscillatorNode"
1010PASS Executing "PannerNode"
11 FAIL Executing "StereoPannerNode" promise_test: Unhandled rejection with value: object "TypeError: undefined is not a constructor (evaluating 'new window[test.nodeName](context)')"
 11PASS Executing "StereoPannerNode"
1212PASS Executing "AudioListener"
1313PASS Audit report
1414PASS > [AudioBufferSourceNode]

@@PASS Set PannerNode.orientationZ.automationRate to "k-rate" did not throw an e
8787PASS PannerNode.orientationZ.automationRate is equal to k-rate.
8888FAIL < [PannerNode] 6 out of 18 assertions were failed. assert_true: expected true got false
8989PASS > [StereoPannerNode]
 90FAIL X Default StereoPannerNode.pan.automationRate is not equal to a-rate. Got undefined. assert_true: expected true got false
 91PASS Set StereoPannerNode.pan.automationRate to "k-rate" did not throw an exception.
 92PASS StereoPannerNode.pan.automationRate is equal to k-rate.
 93FAIL < [StereoPannerNode] 1 out of 3 assertions were failed. assert_true: expected true got false
9094PASS > [AudioListener]
9195FAIL X Default AudioListener.positionX.automationRate is not equal to a-rate. Got undefined. assert_true: expected true got false
9296PASS Set AudioListener.positionX.automationRate to "k-rate" did not throw an exception.

@@FAIL X Default AudioListener.upZ.automationRate is not equal to a-rate. Got unde
116120PASS Set AudioListener.upZ.automationRate to "k-rate" did not throw an exception.
117121PASS AudioListener.upZ.automationRate is equal to k-rate.
118122FAIL < [AudioListener] 9 out of 27 assertions were failed. assert_true: expected true got false
119 FAIL # AUDIT TASK RUNNER FINISHED: 9 out of 10 tasks were failed. assert_true: expected true got false
 123FAIL # AUDIT TASK RUNNER FINISHED: 10 out of 10 tasks were failed. assert_true: expected true got false
120124

LayoutTests/imported/w3c/web-platform-tests/webaudio/the-audio-api/the-audioparam-interface/k-rate-connections-expected.txt

11
22PASS # AUDIT TASK RUNNER STARTED.
33PASS Executing "Gain"
4 FAIL Executing "StereoPanner" promise_test: Unhandled rejection with value: object "TypeError: undefined is not a constructor (evaluating 'new window[nodeName](context)')"
 4PASS Executing "StereoPanner"
55PASS Audit report
66PASS > [Gain] k-rate GainNode.gain
77PASS gain[0:128] contains only the constant 2.

@@PASS gain[768:896] contains only the constant 2.
1414PASS gain[896:1024] contains only the constant 2.
1515PASS < [Gain] All assertions passed. (total 8 assertions)
1616PASS > [StereoPanner] k-rate StereoPannerNode.pan
17 PASS # AUDIT TASK RUNNER FINISHED: 2 tasks ran successfully.
 17FAIL X pan[0:128]: Expected 0.5 for all values but found 127 unexpected values:
 18 Index Actual
 19 [1] 0.500766396522522
 20 [2] 0.5015316009521484
 21 [3] 0.5022956728935242
 22 [4] 0.5030585527420044
 23 ...and 123 more errors. assert_true: expected true got false
 24FAIL X pan[128:256]: Expected 0.5879377722740173 for all values but found 127 unexpected values:
 25 Index Actual
 26 [1] 0.588539719581604
 27 [2] 0.5891402363777161
 28 [3] 0.5897394418716431
 29 [4] 0.5903372168540955
 30 ...and 123 more errors. assert_true: expected true got false
 31FAIL X pan[256:384]: Expected 0.6532814502716064 for all values but found 127 unexpected values:
 32 Index Actual
 33 [1] 0.653695821762085
 34 [2] 0.6541085839271545
 35 [3] 0.65451979637146
 36 [4] 0.654929518699646
 37 ...and 123 more errors. assert_true: expected true got false
 38FAIL X pan[384:512]: Expected 0.6935199499130249 for all values but found 127 unexpected values:
 39 Index Actual
 40 [1] 0.6937307119369507
 41 [2] 0.6939398646354675
 42 [3] 0.6941474080085754
 43 [4] 0.6943533420562744
 44 ...and 123 more errors. assert_true: expected true got false
 45FAIL X pan[512:640]: Expected 0.7071067690849304 for all values but found 127 unexpected values:
 46 Index Actual
 47 [1] 0.7071059346199036
 48 [2] 0.707103431224823
 49 [3] 0.7070993185043335
 50 [4] 0.7070934772491455
 51 ...and 123 more errors. assert_true: expected true got false
 52FAIL X pan[640:768]: Expected 0.6935199499130249 for all values but found 127 unexpected values:
 53 Index Actual
 54 [1] 0.6933075189590454
 55 [2] 0.6930934190750122
 56 [3] 0.6928777694702148
 57 [4] 0.6926604509353638
 58 ...and 123 more errors. assert_true: expected true got false
 59FAIL X pan[768:896]: Expected 0.6532814502716064 for all values but found 127 unexpected values:
 60 Index Actual
 61 [1] 0.6528656482696533
 62 [2] 0.6524482369422913
 63 [3] 0.652029275894165
 64 [4] 0.6516088247299194
 65 ...and 123 more errors. assert_true: expected true got false
 66FAIL X pan[896:1024]: Expected 0.5879377722740173 for all values but found 127 unexpected values:
 67 Index Actual
 68 [1] 0.5873345136642456
 69 [2] 0.5867298245429993
 70 [3] 0.5861237049102783
 71 [4] 0.5855162739753723
 72 ...and 123 more errors. assert_true: expected true got false
 73FAIL < [StereoPanner] 8 out of 8 assertions were failed. assert_true: expected true got false
 74FAIL # AUDIT TASK RUNNER FINISHED: 1 out of 2 tasks were failed. assert_true: expected true got false
1875

LayoutTests/imported/w3c/web-platform-tests/webaudio/the-audio-api/the-audioparam-interface/k-rate-stereo-panner-expected.txt

11
22PASS # AUDIT TASK RUNNER STARTED.
3 FAIL Executing "Test k-rate StereoPannerNode" promise_test: Unhandled rejection with value: object "TypeError: undefined is not a constructor (evaluating 'new window[options.nodeName](context, options.nodeOptions)')"
 3PASS Executing "Test k-rate StereoPannerNode"
44PASS Audit report
55PASS > [Test k-rate StereoPannerNode]
 6PASS StereoPannerNode: Setting pan.automationRate to "k-rate" is equal to k-rate.
 7PASS StereoPannerNode: k-rate node: pan.setValueAtTime(0,0) did not throw an exception.
 8PASS StereoPannerNode: k-rate node: pan.linearRampToValueAtTime(0.5,1) did not throw an exception.
 9PASS StereoPannerNode: a-rate node:pan.setValueAtTime(0,0) did not throw an exception.
 10PASS StereoPannerNode: a-rate node:pan.linearRampToValueAtTime(0.5,1) did not throw an exception.
 11PASS StereoPannerNode: Output of k-rate StereoPannerNode is identical to the array [0,0.23952384293079376,0.4507267475128174,0.6086364984512329,0.694581925868988,0.6984009146690369,0.6196420788764954,0.4676179885864258,0.26030316948890686,0.02221057564020157,-0.2185080349445343,-0.43339070677757263,-0.5970298051834106,-0.6900770664215088,-0.7015307545661926,-0.6300363540649414...].
 12PASS StereoPannerNode: Output of a-rate StereoPannerNode is identical to the array [0,0.23952384293079376,0.4507267475128174,0.6086364984512329,0.694581925868988,0.6984009146690369,0.6196420788764954,0.4676179885864258,0.26030316948890686,0.02221057564020157,-0.2185080349445343,-0.43339070677757263,-0.5970298051834106,-0.6900770664215088,-0.7015307545661926,-0.6300363540649414...].
 13PASS StereoPannerNode: Difference between a-rate and k-rate StereoPannerNode is not constantly 0 (contains 3625 different values).
 14PASS < [Test k-rate StereoPannerNode] All assertions passed. (total 8 assertions)
615PASS # AUDIT TASK RUNNER FINISHED: 1 tasks ran successfully.
716

LayoutTests/imported/w3c/web-platform-tests/webaudio/the-audio-api/the-stereopanner-interface/ctor-stereopanner-expected.txt

22PASS # AUDIT TASK RUNNER STARTED.
33PASS Executing "initialize"
44PASS Executing "invalid constructor"
5 FAIL Executing "default constructor" promise_test: Unhandled rejection with value: object "TypeError: Right hand side of instanceof is not an object"
6 FAIL Executing "test AudioNodeOptions" promise_test: Unhandled rejection with value: object "TypeError: undefined is not an object (evaluating 'node[entry.attribute]')"
7 FAIL Executing "constructor with options" promise_test: Unhandled rejection with value: object "ReferenceError: Can't find variable: StereoPannerNode"
 5PASS Executing "default constructor"
 6PASS Executing "test AudioNodeOptions"
 7PASS Executing "constructor with options"
88PASS Audit report
99PASS > [initialize]
1010PASS context = new OfflineAudioContext(...) did not throw an exception.
1111PASS < [initialize] All assertions passed. (total 1 assertions)
1212PASS > [invalid constructor]
13 PASS new StereoPannerNode() threw TypeError: "undefined is not a constructor (evaluating 'new window[name]()')".
14 PASS new StereoPannerNode(1) threw TypeError: "undefined is not a constructor (evaluating 'new window[name](1)')".
15 PASS new StereoPannerNode(context, 42) threw TypeError: "undefined is not a constructor (evaluating 'new window[name](context, 42)')".
 13PASS new StereoPannerNode() threw TypeError: "Not enough arguments".
 14PASS new StereoPannerNode(1) threw TypeError: "Argument 1 ('context') to the StereoPannerNode constructor must be an instance of BaseAudioContext".
 15PASS new StereoPannerNode(context, 42) threw TypeError: "Type error".
1616PASS < [invalid constructor] All assertions passed. (total 3 assertions)
1717PASS > [default constructor]
18 FAIL X node0 = new StereoPannerNode(context) incorrectly threw TypeError: "undefined is not a constructor (evaluating 'new window[name](context, options.constructorOptions)')". assert_true: expected true got false
 18PASS node0 = new StereoPannerNode(context) did not throw an exception.
 19PASS node0 instanceof StereoPannerNode is equal to true.
 20PASS node0.numberOfInputs is equal to 1.
 21PASS node0.numberOfOutputs is equal to 1.
 22PASS node0.channelCount is equal to 2.
 23PASS node0.channelCountMode is equal to clamped-max.
 24PASS node0.channelInterpretation is equal to speakers.
 25PASS node0.pan.value is equal to 0.
 26PASS < [default constructor] All assertions passed. (total 8 assertions)
1927PASS > [test AudioNodeOptions]
20 FAIL X new StereoPannerNode(c, {"channelCount":1}) incorrectly threw ReferenceError: "Can't find variable: StereoPannerNode". assert_true: expected true got false
 28PASS new StereoPannerNode(c, {"channelCount":1}) did not throw an exception.
 29PASS node.channelCount is equal to 1.
 30PASS new StereoPannerNode(c, {"channelCount":2}) did not throw an exception.
 31PASS node.channelCount is equal to 2.
 32PASS new StereoPannerNode(c, {"channelCount":0}) threw InvalidStateError: "The object is in an invalid state.".
 33PASS new StereoPannerNode(c, {"channelCount":3}) threw NotSupportedError: "StereoPannerNode's channelCount cannot be greater than 2.".
 34PASS new StereoPannerNode(c, {"channelCount":99}) threw NotSupportedError: "StereoPannerNode's channelCount cannot be greater than 2.".
 35PASS new StereoPannerNode(c, {"channelCountMode":"clamped-max"}) did not throw an exception.
 36PASS node.channelCountMode is equal to clamped-max.
 37PASS new StereoPannerNode(c, {"channelCountMode":"explicit"}) did not throw an exception.
 38PASS node.channelCountMode is equal to explicit.
 39PASS new StereoPannerNode(c, {"channelCountMode":"max"}) threw NotSupportedError: "StereoPannerNode's channelCountMode cannot be max.".
 40PASS new StereoPannerNode(c, {"channelCountMode":"foobar"}) threw TypeError: "Type error".
 41PASS new StereoPannerNode(c, {"channelInterpretation":"speakers"}) did not throw an exception.
 42PASS node.channelInterpretation is equal to speakers.
 43PASS new StereoPannerNode(c, {"channelInterpretation":"discrete"}) did not throw an exception.
 44PASS node.channelInterpretation is equal to discrete.
 45PASS new StereoPannerNode(c, {"channelInterpretation":"foobar"}) threw TypeError: "Type error".
 46PASS < [test AudioNodeOptions] All assertions passed. (total 18 assertions)
2147PASS > [constructor with options]
22 FAIL X node1 = new StereoPannerNode(, {"pan":0.75}) incorrectly threw ReferenceError: "Can't find variable: StereoPannerNode". assert_true: expected true got false
23 FAIL # AUDIT TASK RUNNER FINISHED: 3 out of 5 tasks were failed. assert_true: expected true got false
 48PASS node1 = new StereoPannerNode(, {"pan":0.75}) did not throw an exception.
 49PASS node1 instanceof StereoPannerNode is equal to true.
 50PASS node1.pan.value is equal to 0.75.
 51PASS < [constructor with options] All assertions passed. (total 3 assertions)
 52PASS # AUDIT TASK RUNNER FINISHED: 5 tasks ran successfully.
2453

LayoutTests/imported/w3c/web-platform-tests/webaudio/the-audio-api/the-stereopanner-interface/no-dezippering-expected.txt

11
22PASS # AUDIT TASK RUNNER STARTED.
3 FAIL Executing "test mono input" promise_test: Unhandled rejection with value: object "ReferenceError: Can't find variable: StereoPannerNode"
4 FAIL Executing "test stereo input" promise_test: Unhandled rejection with value: object "ReferenceError: Can't find variable: StereoPannerNode"
5 FAIL Executing "test mono input setValue" promise_test: Unhandled rejection with value: object "ReferenceError: Can't find variable: StereoPannerNode"
6 FAIL Executing "test stereo input setValue" promise_test: Unhandled rejection with value: object "ReferenceError: Can't find variable: StereoPannerNode"
7 FAIL Executing "test mono input automation" promise_test: Unhandled rejection with value: object "ReferenceError: Can't find variable: StereoPannerNode"
 3PASS Executing "test mono input"
 4PASS Executing "test stereo input"
 5PASS Executing "test mono input setValue"
 6PASS Executing "test stereo input setValue"
 7PASS Executing "test mono input automation"
88PASS Audit report
99PASS > [test mono input] Test StereoPanner with mono input has no dezippering
 10FAIL X Mono: Left channel, pan = -1: : Expected 1 for all values but found 256 unexpected values:
 11 Index Actual
 12 [0] 6.123234262925839e-17
 13 [1] 6.123234262925839e-17
 14 [2] 6.123234262925839e-17
 15 [3] 6.123234262925839e-17
 16 ...and 252 more errors. assert_true: expected true got false
 17FAIL X Mono: Right channel, pan = -1:: Expected 0 for all values but found 256 unexpected values:
 18 Index Actual
 19 [0] 1
 20 [1] 1
 21 [2] 1
 22 [3] 1
 23 ...and 252 more errors. assert_true: expected true got false
 24PASS Mono: Left channel, pan = 1: equals [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0...] with an element-wise tolerance of {"absoluteThreshold":6.1233e-17,"relativeThreshold":0}.
 25FAIL X Mono: Right channel, pan = 1:: Expected 1 for all values but found 256 unexpected values:
 26 Index Actual
 27 [15872] 0
 28 [15873] 0
 29 [15874] 0
 30 [15875] 0
 31 ...and 252 more errors. assert_true: expected true got false
 32FAIL < [test mono input] 3 out of 4 assertions were failed. assert_true: expected true got false
1033PASS > [test stereo input] Test StereoPanner with stereo input has no dezippering
 34FAIL X Stereo: Left channel, pan = -1: : Expected 3 for all values but found 256 unexpected values:
 35 Index Actual
 36 [0] 6.123234262925839e-17
 37 [1] 6.123234262925839e-17
 38 [2] 6.123234262925839e-17
 39 [3] 6.123234262925839e-17
 40 ...and 252 more errors. assert_true: expected true got false
 41FAIL X Stereo: Right channel, pan = -1:: Expected 0 for all values but found 256 unexpected values:
 42 Index Actual
 43 [0] 3
 44 [1] 3
 45 [2] 3
 46 [3] 3
 47 ...and 252 more errors. assert_true: expected true got false
 48PASS Stereo: Left channel, pan = 1: equals [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0...] with an element-wise tolerance of {"absoluteThreshold":6.1233e-17,"relativeThreshold":0}.
 49FAIL X Stereo: Right channel, pan = 1:: Expected 3 for all values but found 256 unexpected values:
 50 Index Actual
 51 [15872] 0
 52 [15873] 0
 53 [15874] 0
 54 [15875] 0
 55 ...and 252 more errors. assert_true: expected true got false
 56FAIL < [test stereo input] 3 out of 4 assertions were failed. assert_true: expected true got false
1157PASS > [test mono input setValue] Test StereoPanner with mono input value setter vs setValueAtTime
 58PASS Mono Left .value setter output is identical to the array [0.20861317217350006,0.19113875925540924,0.16823500394821167,0.1405525654554367,0.10887773334980011,0.07411020249128342,0.037237610667943954,-0.0006927690701559186,-0.03860342130064964,-0.07541755586862564,-0.11008944362401962,-0.1416342556476593,-0.16915595531463623,-0.1918727606534958,-0.20913946628570557,-0.2204655408859253...].
 59PASS Mono Left .value setter output matches setValueAtTime output is true.
 60PASS Mono Right .value setter output is identical to the array [0.9000188112258911,0.8246290683746338,0.7258154153823853,0.6063852310180664,0.4697306752204895,0.31973329186439514,0.16065403819084167,-0.002988810185343027,-0.1665465533733368,-0.3253736197948456,-0.4749583601951599,-0.6110519766807556,-0.7297887206077576,-0.8277957439422607,-0.9022893905639648,-0.9511533975601196...].
 61PASS Mono Right .value setter output matches setValueAtTime output is true.
 62PASS < [test mono input setValue] All assertions passed. (total 4 assertions)
1263PASS > [test stereo input setValue] Test StereoPanner with mono input value setter vs setValueAtTime
 64PASS Stereo Left .value setter output is identical to the array [-0.4399392008781433,-0.4193967282772064,-0.3596876561641693,-0.2663879990577698,-0.1482110172510147,-0.01619294472038746,0.11733736842870712,0.2399098426103592,0.34007757902145386,0.4084862470626831,0.4387471675872803,0.42803439497947693,0.377348393201828,0.29142266511917114,0.1782815307378769,0.048491086810827255...].
 65PASS Stereo Left .value setter output matches setValueAtTime output is true.
 66PASS Stereo Right .value setter output is identical to the array [-1.671038031578064,-1.5648269653320312,-1.3721576929092407,-1.1050618886947632,-0.7820299863815308,-0.4263407588005066,-0.06395263969898224,0.2788553237915039,0.5778660178184509,0.8131168484687805,0.9706887006759644,1.0439329147338867,1.0340183973312378,0.9497482180595398,0.8066650629043579,0.6255297064781189...].
 67PASS Stereo Right .value setter output matches setValueAtTime output is true.
 68PASS < [test stereo input setValue] All assertions passed. (total 4 assertions)
1369PASS > [test mono input automation] Test StereoPanner with mono input and automation
14 PASS # AUDIT TASK RUNNER FINISHED: 5 tasks ran successfully.
 70PASS Modulated Stereo Left .value setter output is identical to the array [-6.123234262925839e-17,-5.83731630634668e-17,-5.006263826782414e-17,-3.707685225408482e-17,-2.062854940756385e-17,-2.253792958833939e-18,1.6331442078301927e-17,3.3391524397144665e-17,4.733323672269722e-17,5.685460504260725e-17,6.106643005071496e-17,5.957538736575137e-17,5.252072126331122e-17,4.056126455768074e-17,2.481387320320658e-17,6.749165968347778e-18...].
 71PASS Modulated Stereo Left .value setter output matches setValueAtTime output is true.
 72PASS Modulated Stereo Right .value setter output is identical to the array [-1.773010492324829,-1.6620378494262695,-1.455528736114502,-1.1668072938919067,-0.8163834810256958,-0.4300940930843353,-0.03675529360771179,0.3344634473323822,0.6566917896270752,0.9077988862991333,1.0723848342895508,1.14314603805542,1.1214830875396729,1.017296314239502,0.847988486289978,0.6367692947387695...].
 73PASS Modulated Stereo Right .value setter output matches setValueAtTime output is true.
 74PASS < [test mono input automation] All assertions passed. (total 4 assertions)
 75FAIL # AUDIT TASK RUNNER FINISHED: 2 out of 5 tasks were failed. assert_true: expected true got false
1576

LayoutTests/imported/w3c/web-platform-tests/webaudio/the-audio-api/the-stereopanner-interface/stereopannernode-basic-expected.txt

11
22PASS # AUDIT TASK RUNNER STARTED.
3 FAIL Executing "test" promise_test: Unhandled rejection with value: object "TypeError: context.createStereoPanner is not a function. (In 'context.createStereoPanner()', 'context.createStereoPanner' is undefined)"
 3PASS Executing "test"
44PASS Audit report
55PASS > [test] Attributes and basic functionality of StereoPannerNode
 6PASS panner.numberOfInputs is equal to 1.
 7PASS panner.numberOfOutputs is equal to 1.
 8PASS panner.pan.defaultValue is equal to 0.
 9PASS panner.pan.value = 1.0 did not throw an exception.
 10PASS panner.pan.value is equal to 1.
 11PASS panner.channelCount = 1 did not throw an exception.
 12PASS panner.channelCount = 3 threw NotSupportedError: "StereoPannerNode's channelCount cannot be greater than 2.".
 13PASS panner.channelCountMode = "explicit" did not throw an exception.
 14PASS panner.channelCountMode = "max" threw NotSupportedError: "StereoPannerNode's channelCountMode cannot be max.".
 15PASS < [test] All assertions passed. (total 9 assertions)
616PASS # AUDIT TASK RUNNER FINISHED: 1 tasks ran successfully.
717

LayoutTests/imported/w3c/web-platform-tests/webaudio/the-audio-api/the-stereopanner-interface/stereopannernode-panning-expected.txt

11
22PASS # AUDIT TASK RUNNER STARTED.
3 FAIL Executing "mono-test" promise_test: Unhandled rejection with value: object "TypeError: this.context.createStereoPanner is not a function. (In 'this.context.createStereoPanner()', 'this.context.createStereoPanner' is undefined)"
4 FAIL Executing "stereo-test" promise_test: Unhandled rejection with value: object "TypeError: this.context.createStereoPanner is not a function. (In 'this.context.createStereoPanner()', 'this.context.createStereoPanner' is undefined)"
 3PASS Executing "mono-test"
 4PASS Executing "stereo-test"
55PASS Audit report
66PASS > [mono-test]
 7PASS Mono: Number of impulses found is equal to 100.
 8PASS Mono: Number of impulse at the wrong offset is equal to 0.
 9PASS Mono: Left channel error magnitude is less than or equal to 9.8015e-8.
 10PASS Mono: Right channel error magnitude is less than or equal to 9.8015e-8.
 11PASS < [mono-test] All assertions passed. (total 4 assertions)
712PASS > [stereo-test]
 13PASS Stereo: Number of impulses found is equal to 100.
 14PASS Stereo: Number of impulse at the wrong offset is equal to 0.
 15PASS Stereo: Left channel error magnitude is less than or equal to 9.8015e-8.
 16PASS Stereo: Right channel error magnitude is less than or equal to 9.8015e-8.
 17PASS < [stereo-test] All assertions passed. (total 4 assertions)
818PASS # AUDIT TASK RUNNER FINISHED: 2 tasks ran successfully.
919