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

Unified Diff: media/base/audio_renderer_mixer.h

Issue 1942803002: Caching AudioOutputDevice instances in mixer manager (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: First round of comments addressed Created 4 years, 7 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: media/base/audio_renderer_mixer.h
diff --git a/media/base/audio_renderer_mixer.h b/media/base/audio_renderer_mixer.h
index 7a6c1dd781bb96572e51dd71bbe96247d6ae6566..4d32dc6d7824b9840584e5c7d4d570d40361fe46 100644
--- a/media/base/audio_renderer_mixer.h
+++ b/media/base/audio_renderer_mixer.h
@@ -27,7 +27,7 @@ class MEDIA_EXPORT AudioRendererMixer
: NON_EXPORTED_BASE(public AudioRendererSink::RenderCallback) {
public:
AudioRendererMixer(const AudioParameters& output_params,
- const scoped_refptr<AudioRendererSink>& sink);
+ scoped_refptr<media::AudioRendererSink> sink);
DaleCurtis 2016/05/17 19:13:48 Remove media:: this is already in media. Ditto bel
o1ka 2016/05/18 13:15:12 Done.
~AudioRendererMixer() override;
// Add or remove a mixer input from mixing; called by AudioRendererMixerInput.
@@ -48,6 +48,8 @@ class MEDIA_EXPORT AudioRendererMixer
OutputDeviceInfo GetOutputDeviceInfo();
+ const AudioRendererSink* sink_ptr() { return audio_sink_.get(); };
DaleCurtis 2016/05/17 19:13:48 Needed? for_testing?
o1ka 2016/05/18 13:15:12 Needed, I put it into the comment. Maybe you have
+
private:
// Maps input sample rate to the dedicated converter.
using AudioConvertersMap =
@@ -64,10 +66,10 @@ class MEDIA_EXPORT AudioRendererMixer
}
// Output sink for this mixer.
- scoped_refptr<AudioRendererSink> audio_sink_;
+ const scoped_refptr<media::AudioRendererSink> audio_sink_;
// Output parameters for this mixer.
- AudioParameters output_params_;
+ const AudioParameters output_params_;
// ---------------[ All variables below protected by |lock_| ]---------------
base::Lock lock_;

Powered by Google App Engine
This is Rietveld 408576698