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

Unified Diff: third_party/WebKit/Source/modules/webaudio/AudioParamTimeline.h

Issue 2033503004: Avoid slow AudioParam automation path when possible (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address review comments Created 4 years, 6 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/AudioParamTimeline.h
diff --git a/third_party/WebKit/Source/modules/webaudio/AudioParamTimeline.h b/third_party/WebKit/Source/modules/webaudio/AudioParamTimeline.h
index 2f799a6e35bae8c87c007e51172b31b2018fcc63..4fee60733e96b4685aaa3a1bbbafd13957630231 100644
--- a/third_party/WebKit/Source/modules/webaudio/AudioParamTimeline.h
+++ b/third_party/WebKit/Source/modules/webaudio/AudioParamTimeline.h
@@ -67,6 +67,8 @@ public:
// Returns true if this AudioParam has any events on it.
bool hasValues() const;
+ float smoothedValue() { return m_smoothedValue; }
+ void setSmoothedValue(float v) { m_smoothedValue = v; }
private:
class ParamEvent {
public:
@@ -121,6 +123,9 @@ private:
Vector<ParamEvent> m_events;
mutable Mutex m_eventsLock;
+
+ // Smoothing (de-zippering)
+ float m_smoothedValue;
};
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698