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

Unified Diff: media/audio/clockless_audio_sink.h

Issue 1122393004: Add support for switching the audio output device for HTMLMediaElements. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Changes to MediaPlayers so that they invoke callbacks in the correct threads. First complete implem… Created 5 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/audio/clockless_audio_sink.h
diff --git a/media/audio/clockless_audio_sink.h b/media/audio/clockless_audio_sink.h
index 075c55a50d72285a88d143a57d55a8f1c3f4e5ba..1d1db626235b6b4da7e7995a4e18e6f838e39284 100644
--- a/media/audio/clockless_audio_sink.h
+++ b/media/audio/clockless_audio_sink.h
@@ -5,9 +5,12 @@
#ifndef MEDIA_AUDIO_CLOCKLESS_AUDIO_SINK_H_
#define MEDIA_AUDIO_CLOCKLESS_AUDIO_SINK_H_
+#include <string>
+
#include "base/memory/scoped_ptr.h"
#include "base/time/time.h"
#include "media/base/audio_renderer_sink.h"
+#include "url/gurl.h"
namespace base {
class SingleThreadTaskRunner;
@@ -32,6 +35,9 @@ class MEDIA_EXPORT ClocklessAudioSink
void Pause() override;
void Play() override;
bool SetVolume(double volume) override;
+ void SwitchOutputDevice(const std::string& device_id,
+ const GURL& security_origin,
+ const base::Callback<void(int)>& callback) override;
// Returns the time taken to consume all the audio.
base::TimeDelta render_time() { return playback_time_; }

Powered by Google App Engine
This is Rietveld 408576698