Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(141)

Side by Side Diff: third_party/WebKit/Source/modules/webaudio/StereoPannerNode.cpp

Issue 2272683003: Remove redundant definition of Spatializer abstract class (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix reference URL Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "modules/webaudio/StereoPannerNode.h" 5 #include "modules/webaudio/StereoPannerNode.h"
6 #include "bindings/core/v8/ExceptionMessages.h" 6 #include "bindings/core/v8/ExceptionMessages.h"
7 #include "bindings/core/v8/ExceptionState.h" 7 #include "bindings/core/v8/ExceptionState.h"
8 #include "core/dom/ExceptionCode.h" 8 #include "core/dom/ExceptionCode.h"
9 #include "core/dom/ExecutionContext.h" 9 #include "core/dom/ExecutionContext.h"
10 #include "modules/webaudio/AudioNodeInput.h" 10 #include "modules/webaudio/AudioNodeInput.h"
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 } else { 68 } else {
69 m_stereoPanner->panToTargetValue(inputBus, outputBus, m_pan->value(), fr amesToProcess); 69 m_stereoPanner->panToTargetValue(inputBus, outputBus, m_pan->value(), fr amesToProcess);
70 } 70 }
71 } 71 }
72 72
73 void StereoPannerHandler::initialize() 73 void StereoPannerHandler::initialize()
74 { 74 {
75 if (isInitialized()) 75 if (isInitialized())
76 return; 76 return;
77 77
78 m_stereoPanner = Spatializer::create(Spatializer::PanningModelEqualPower, sa mpleRate()); 78 m_stereoPanner = StereoPanner::create(sampleRate());
79 79
80 AudioHandler::initialize(); 80 AudioHandler::initialize();
81 } 81 }
82 82
83 void StereoPannerHandler::setChannelCount(unsigned long channelCount, ExceptionS tate& exceptionState) 83 void StereoPannerHandler::setChannelCount(unsigned long channelCount, ExceptionS tate& exceptionState)
84 { 84 {
85 DCHECK(isMainThread()); 85 DCHECK(isMainThread());
86 BaseAudioContext::AutoLocker locker(context()); 86 BaseAudioContext::AutoLocker locker(context());
87 87
88 // A PannerNode only supports 1 or 2 channels 88 // A PannerNode only supports 1 or 2 channels
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 AudioNode::trace(visitor); 150 AudioNode::trace(visitor);
151 } 151 }
152 152
153 AudioParam* StereoPannerNode::pan() const 153 AudioParam* StereoPannerNode::pan() const
154 { 154 {
155 return m_pan; 155 return m_pan;
156 } 156 }
157 157
158 } // namespace blink 158 } // namespace blink
159 159
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/modules/webaudio/StereoPannerNode.h ('k') | third_party/WebKit/Source/platform/audio/Spatializer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698