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

Unified Diff: third_party/WebKit/Source/modules/webaudio/OscillatorNode.cpp

Issue 1928163002: Add a name attribute for each AudioParam (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Use enum instead of string Created 4 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/modules/webaudio/OscillatorNode.cpp
diff --git a/third_party/WebKit/Source/modules/webaudio/OscillatorNode.cpp b/third_party/WebKit/Source/modules/webaudio/OscillatorNode.cpp
index 07b2a655dd6018cf33994f51bf794ab81edd9f19..593ba560afcc5f74eef22310875f5b627e6c3c2c 100644
--- a/third_party/WebKit/Source/modules/webaudio/OscillatorNode.cpp
+++ b/third_party/WebKit/Source/modules/webaudio/OscillatorNode.cpp
@@ -333,9 +333,9 @@ bool OscillatorHandler::propagatesSilence() const
OscillatorNode::OscillatorNode(AbstractAudioContext& context, float sampleRate)
: AudioScheduledSourceNode(context)
// Use musical pitch standard A440 as a default.
- , m_frequency(AudioParam::create(context, 440))
+ , m_frequency(AudioParam::create(context, AudioParamHandler::OscillatorFrequency, 440))
// Default to no detuning.
- , m_detune(AudioParam::create(context, 0))
+ , m_detune(AudioParam::create(context, AudioParamHandler::OscillatorDetune, 0))
{
setHandler(OscillatorHandler::create(*this, sampleRate, m_frequency->handler(), m_detune->handler()));
}

Powered by Google App Engine
This is Rietveld 408576698