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

Unified Diff: media/blink/webmediaplayer_impl.h

Issue 1567123002: Support CAST+WMPI on android (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: comments addressed Created 4 years, 11 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/blink/webmediaplayer_impl.h
diff --git a/media/blink/webmediaplayer_impl.h b/media/blink/webmediaplayer_impl.h
index 8fbd6b56aa0a2d4843ff3e671d89aae2ce349274..60ba8023e85f46fff621807b905157de0403c97f 100644
--- a/media/blink/webmediaplayer_impl.h
+++ b/media/blink/webmediaplayer_impl.h
@@ -36,6 +36,11 @@
#include "third_party/WebKit/public/platform/WebMediaPlayer.h"
#include "url/gurl.h"
+#if defined(OS_ANDROID) // WMPI_CAST
+// Delete this file when WMPI_CAST is no longer needed.
+#include "media/blink/webmediaplayer_cast_android.h"
+#endif
+
namespace blink {
class WebGraphicsContext3D;
class WebLocalFrame;
@@ -197,10 +202,32 @@ class MEDIA_BLINK_EXPORT WebMediaPlayerImpl
void OnHidden() override;
void OnShown() override;
+#if defined(OS_ANDROID) // WMPI_CAST
+ void requestRemotePlayback() override;
+ void requestRemotePlaybackControl() override;
+
+ void set_media_player_manager(
+ RendererMediaPlayerManagerInterface* media_player_manager);
+ void OnRemotePlaybackEnded();
+ void OnDisconnectedFromRemoteDevice(double t);
+ void SuspendForRemote();
+ void DisplayCastFrameAfterSuspend(const scoped_refptr<VideoFrame>& new_frame,
+ PipelineStatus status);
+ gfx::Size GetCanvasSize() const;
+#endif
+
private:
+ // Ask for the pipeline to be suspended, will call Suspend() when ready.
+ // (Possibly immediately.)
+ void ScheduleSuspend();
+
// Initiate suspending the pipeline.
void Suspend();
+ // Ask for the pipeline to be resumed, will call Resume() when ready.
+ // (Possibly immediately.)
+ void ScheduleResume();
+
// Initiate resuming the pipeline.
void Resume();
@@ -408,6 +435,10 @@ class MEDIA_BLINK_EXPORT WebMediaPlayerImpl
// Whether a CDM has been successfully attached.
bool is_cdm_attached_;
+#if defined(OS_ANDROID) // WMPI_CAST
+ WebMediaPlayerCast cast_impl_;
+#endif
+
scoped_ptr<RendererFactory> renderer_factory_;
DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerImpl);

Powered by Google App Engine
This is Rietveld 408576698