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

Unified Diff: Source/modules/webaudio/AudioContext.h

Issue 386403002: WebAudio: Split AudioNode::finishDeref into two parts. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: apply review comments Created 6 years, 5 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
« no previous file with comments | « no previous file | Source/modules/webaudio/AudioContext.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/webaudio/AudioContext.h
diff --git a/Source/modules/webaudio/AudioContext.h b/Source/modules/webaudio/AudioContext.h
index ed31ce8b9910eae3fa5643d43b5e2232fed3b51d..f8d09b96145d89410642a2f34dc71535aaf680ae 100644
--- a/Source/modules/webaudio/AudioContext.h
+++ b/Source/modules/webaudio/AudioContext.h
@@ -203,11 +203,13 @@ public:
bool m_mustReleaseLock;
};
- // In AudioNode::deref() a tryLock() is used for calling finishDeref(), but if it fails keep track here.
+ // In AudioNode::breakConnection() and deref(), a tryLock() is used for
+ // calling actual processing, but if it fails keep track here.
+ void addDeferredBreakConnection(AudioNode&);
void addDeferredFinishDeref(AudioNode*);
- // In the audio thread at the start of each render cycle, we'll call handleDeferredFinishDerefs().
- void handleDeferredFinishDerefs();
+ // In the audio thread at the start of each render cycle, we'll call this.
+ void handleDeferredAudioNodeTasks();
// Only accessed when the graph lock is held.
void markSummingJunctionDirty(AudioSummingJunction*);
@@ -306,6 +308,7 @@ private:
volatile ThreadIdentifier m_graphOwnerThread; // if the lock is held then this is the thread which owns it, otherwise == UndefinedThreadIdentifier
// Only accessed in the audio thread.
+ Vector<AudioNode*> m_deferredBreakConnectionList;
Vector<AudioNode*> m_deferredFinishDerefList;
RefPtrWillBeMember<AudioBuffer> m_renderTarget;
« no previous file with comments | « no previous file | Source/modules/webaudio/AudioContext.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698