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

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

Issue 2809923004: AnalyserNode.channelCount should be 1 (Closed)
Patch Set: Rebase Created 3 years, 7 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
« no previous file with comments | « third_party/WebKit/LayoutTests/webaudio/constructor/analyser.html ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010, Google Inc. All rights reserved. 2 * Copyright (C) 2010, Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 16 matching lines...) Expand all
27 #include "bindings/core/v8/ExceptionMessages.h" 27 #include "bindings/core/v8/ExceptionMessages.h"
28 #include "bindings/core/v8/ExceptionState.h" 28 #include "bindings/core/v8/ExceptionState.h"
29 #include "core/dom/ExceptionCode.h" 29 #include "core/dom/ExceptionCode.h"
30 #include "modules/webaudio/AnalyserOptions.h" 30 #include "modules/webaudio/AnalyserOptions.h"
31 #include "modules/webaudio/AudioNodeInput.h" 31 #include "modules/webaudio/AudioNodeInput.h"
32 #include "modules/webaudio/AudioNodeOutput.h" 32 #include "modules/webaudio/AudioNodeOutput.h"
33 33
34 namespace blink { 34 namespace blink {
35 35
36 AnalyserHandler::AnalyserHandler(AudioNode& node, float sample_rate) 36 AnalyserHandler::AnalyserHandler(AudioNode& node, float sample_rate)
37 : AudioBasicInspectorHandler(kNodeTypeAnalyser, node, sample_rate, 2) { 37 : AudioBasicInspectorHandler(kNodeTypeAnalyser, node, sample_rate, 1) {
38 channel_count_ = 1;
38 Initialize(); 39 Initialize();
39 } 40 }
40 41
41 PassRefPtr<AnalyserHandler> AnalyserHandler::Create(AudioNode& node, 42 PassRefPtr<AnalyserHandler> AnalyserHandler::Create(AudioNode& node,
42 float sample_rate) { 43 float sample_rate) {
43 return AdoptRef(new AnalyserHandler(node, sample_rate)); 44 return AdoptRef(new AnalyserHandler(node, sample_rate));
44 } 45 }
45 46
46 AnalyserHandler::~AnalyserHandler() { 47 AnalyserHandler::~AnalyserHandler() {
47 Uninitialize(); 48 Uninitialize();
(...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after
274 275
275 void AnalyserNode::getFloatTimeDomainData(NotShared<DOMFloat32Array> array) { 276 void AnalyserNode::getFloatTimeDomainData(NotShared<DOMFloat32Array> array) {
276 GetAnalyserHandler().GetFloatTimeDomainData(array.View()); 277 GetAnalyserHandler().GetFloatTimeDomainData(array.View());
277 } 278 }
278 279
279 void AnalyserNode::getByteTimeDomainData(NotShared<DOMUint8Array> array) { 280 void AnalyserNode::getByteTimeDomainData(NotShared<DOMUint8Array> array) {
280 GetAnalyserHandler().GetByteTimeDomainData(array.View()); 281 GetAnalyserHandler().GetByteTimeDomainData(array.View());
281 } 282 }
282 283
283 } // namespace blink 284 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/webaudio/constructor/analyser.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698