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

Side by Side Diff: third_party/WebKit/Source/modules/webaudio/BiquadFilterNode.h

Issue 2102133002: Add constructors for WebAudio nodes (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase and prefix use counter names with WebAudio 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 /* 1 /*
2 * Copyright (C) 2011, Google Inc. All rights reserved. 2 * Copyright (C) 2011, 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 15 matching lines...) Expand all
26 #define BiquadFilterNode_h 26 #define BiquadFilterNode_h
27 27
28 #include "core/dom/DOMTypedArray.h" 28 #include "core/dom/DOMTypedArray.h"
29 #include "modules/webaudio/AudioNode.h" 29 #include "modules/webaudio/AudioNode.h"
30 #include "modules/webaudio/BiquadProcessor.h" 30 #include "modules/webaudio/BiquadProcessor.h"
31 31
32 namespace blink { 32 namespace blink {
33 33
34 class BaseAudioContext; 34 class BaseAudioContext;
35 class AudioParam; 35 class AudioParam;
36 class BiquadFilterOptions;
36 37
37 class BiquadFilterNode final : public AudioNode { 38 class BiquadFilterNode final : public AudioNode {
38 DEFINE_WRAPPERTYPEINFO(); 39 DEFINE_WRAPPERTYPEINFO();
39 public: 40 public:
40 // These must be defined as in the .idl file and must match those in the Biq uadProcessor class. 41 // These must be defined as in the .idl file and must match those in the Biq uadProcessor class.
41 enum { 42 enum {
42 LOWPASS = 0, 43 LOWPASS = 0,
43 HIGHPASS = 1, 44 HIGHPASS = 1,
44 BANDPASS = 2, 45 BANDPASS = 2,
45 LOWSHELF = 3, 46 LOWSHELF = 3,
46 HIGHSHELF = 4, 47 HIGHSHELF = 4,
47 PEAKING = 5, 48 PEAKING = 5,
48 NOTCH = 6, 49 NOTCH = 6,
49 ALLPASS = 7 50 ALLPASS = 7
50 }; 51 };
51 52
52 static BiquadFilterNode* create(BaseAudioContext&, ExceptionState&); 53 static BiquadFilterNode* create(BaseAudioContext&, ExceptionState&);
54 static BiquadFilterNode* create(BaseAudioContext*, const BiquadFilterOptions &, ExceptionState&);
53 55
54 DECLARE_VIRTUAL_TRACE(); 56 DECLARE_VIRTUAL_TRACE();
55 57
56 String type() const; 58 String type() const;
57 void setType(const String&); 59 void setType(const String&);
58 60
59 AudioParam* frequency() { return m_frequency; } 61 AudioParam* frequency() { return m_frequency; }
60 AudioParam* q() { return m_q; } 62 AudioParam* q() { return m_q; }
61 AudioParam* gain() { return m_gain; } 63 AudioParam* gain() { return m_gain; }
62 AudioParam* detune() { return m_detune; } 64 AudioParam* detune() { return m_detune; }
(...skipping 10 matching lines...) Expand all
73 75
74 Member<AudioParam> m_frequency; 76 Member<AudioParam> m_frequency;
75 Member<AudioParam> m_q; 77 Member<AudioParam> m_q;
76 Member<AudioParam> m_gain; 78 Member<AudioParam> m_gain;
77 Member<AudioParam> m_detune; 79 Member<AudioParam> m_detune;
78 }; 80 };
79 81
80 } // namespace blink 82 } // namespace blink
81 83
82 #endif // BiquadFilterNode_h 84 #endif // BiquadFilterNode_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698