| Index: third_party/WebKit/Source/modules/webaudio/ScriptProcessorNode.cpp
|
| diff --git a/third_party/WebKit/Source/modules/webaudio/ScriptProcessorNode.cpp b/third_party/WebKit/Source/modules/webaudio/ScriptProcessorNode.cpp
|
| index 6f26b7d3d951a565623fab7b6ed7e101915fbb99..704b397ebbb58c4fbe5935f19cf7d51f2a1aee35 100644
|
| --- a/third_party/WebKit/Source/modules/webaudio/ScriptProcessorNode.cpp
|
| +++ b/third_party/WebKit/Source/modules/webaudio/ScriptProcessorNode.cpp
|
| @@ -27,11 +27,11 @@
|
| #include "core/dom/CrossThreadTask.h"
|
| #include "core/dom/ExceptionCode.h"
|
| #include "core/dom/ExecutionContext.h"
|
| -#include "modules/webaudio/AbstractAudioContext.h"
|
| #include "modules/webaudio/AudioBuffer.h"
|
| #include "modules/webaudio/AudioNodeInput.h"
|
| #include "modules/webaudio/AudioNodeOutput.h"
|
| #include "modules/webaudio/AudioProcessingEvent.h"
|
| +#include "modules/webaudio/BaseAudioContext.h"
|
| #include "public/platform/Platform.h"
|
|
|
| namespace blink {
|
| @@ -49,7 +49,7 @@ ScriptProcessorHandler::ScriptProcessorHandler(AudioNode& node, float sampleRate
|
| if (m_bufferSize < ProcessingSizeInFrames)
|
| m_bufferSize = ProcessingSizeInFrames;
|
|
|
| - ASSERT(numberOfInputChannels <= AbstractAudioContext::maxNumberOfChannels());
|
| + ASSERT(numberOfInputChannels <= BaseAudioContext::maxNumberOfChannels());
|
|
|
| addInput();
|
| addOutput(numberOfOutputChannels);
|
| @@ -213,7 +213,7 @@ double ScriptProcessorHandler::latencyTime() const
|
| void ScriptProcessorHandler::setChannelCount(unsigned long channelCount, ExceptionState& exceptionState)
|
| {
|
| ASSERT(isMainThread());
|
| - AbstractAudioContext::AutoLocker locker(context());
|
| + BaseAudioContext::AutoLocker locker(context());
|
|
|
| if (channelCount != m_channelCount) {
|
| exceptionState.throwDOMException(
|
| @@ -225,7 +225,7 @@ void ScriptProcessorHandler::setChannelCount(unsigned long channelCount, Excepti
|
| void ScriptProcessorHandler::setChannelCountMode(const String& mode, ExceptionState& exceptionState)
|
| {
|
| ASSERT(isMainThread());
|
| - AbstractAudioContext::AutoLocker locker(context());
|
| + BaseAudioContext::AutoLocker locker(context());
|
|
|
| if ((mode == "max") || (mode == "clamped-max")) {
|
| exceptionState.throwDOMException(
|
| @@ -236,7 +236,7 @@ void ScriptProcessorHandler::setChannelCountMode(const String& mode, ExceptionSt
|
|
|
| // ----------------------------------------------------------------
|
|
|
| -ScriptProcessorNode::ScriptProcessorNode(AbstractAudioContext& context, float sampleRate, size_t bufferSize, unsigned numberOfInputChannels, unsigned numberOfOutputChannels)
|
| +ScriptProcessorNode::ScriptProcessorNode(BaseAudioContext& context, float sampleRate, size_t bufferSize, unsigned numberOfInputChannels, unsigned numberOfOutputChannels)
|
| : AudioNode(context)
|
| , ActiveScriptWrappable(this)
|
| {
|
| @@ -259,7 +259,7 @@ static size_t chooseBufferSize()
|
| return bufferSize;
|
| }
|
|
|
| -ScriptProcessorNode* ScriptProcessorNode::create(AbstractAudioContext& context, float sampleRate, size_t bufferSize, unsigned numberOfInputChannels, unsigned numberOfOutputChannels)
|
| +ScriptProcessorNode* ScriptProcessorNode::create(BaseAudioContext& context, float sampleRate, size_t bufferSize, unsigned numberOfInputChannels, unsigned numberOfOutputChannels)
|
| {
|
| // Check for valid buffer size.
|
| switch (bufferSize) {
|
| @@ -281,10 +281,10 @@ ScriptProcessorNode* ScriptProcessorNode::create(AbstractAudioContext& context,
|
| if (!numberOfInputChannels && !numberOfOutputChannels)
|
| return nullptr;
|
|
|
| - if (numberOfInputChannels > AbstractAudioContext::maxNumberOfChannels())
|
| + if (numberOfInputChannels > BaseAudioContext::maxNumberOfChannels())
|
| return nullptr;
|
|
|
| - if (numberOfOutputChannels > AbstractAudioContext::maxNumberOfChannels())
|
| + if (numberOfOutputChannels > BaseAudioContext::maxNumberOfChannels())
|
| return nullptr;
|
|
|
| return new ScriptProcessorNode(context, sampleRate, bufferSize, numberOfInputChannels, numberOfOutputChannels);
|
|
|