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

Unified Diff: content/renderer/media/webrtc_audio_device_impl.h

Issue 2038053002: Change audio render thread checking to use new AudioRendererSink::BelongsToRendererThread() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Code review fixes (dalecurtis@). 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: content/renderer/media/webrtc_audio_device_impl.h
diff --git a/content/renderer/media/webrtc_audio_device_impl.h b/content/renderer/media/webrtc_audio_device_impl.h
index 6af4a86935616b627b7874177142486df6638100..1e3f05f1a6473f7d7427b6e2033f897cb72a9c34 100644
--- a/content/renderer/media/webrtc_audio_device_impl.h
+++ b/content/renderer/media/webrtc_audio_device_impl.h
@@ -219,7 +219,7 @@ class WebRtcPlayoutDataSource {
class Sink {
public:
// Callback to get the playout data.
- // Called on the render audio thread.
+ // Called on the audio render thread.
virtual void OnPlayoutData(media::AudioBus* audio_bus,
int sample_rate,
int audio_delay_milliseconds) = 0;
@@ -228,6 +228,11 @@ class WebRtcPlayoutDataSource {
// Called on the main render thread.
virtual void OnPlayoutDataSourceChanged() = 0;
+ // Called to notify that the audio render thread has changed, and
+ // OnPlayoutData() will from now on be called on the new thread.
+ // Called on the new audio render thread.
+ virtual void OnRenderThreadChanged() = 0;
+
protected:
virtual ~Sink() {}
};

Powered by Google App Engine
This is Rietveld 408576698