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

Unified Diff: webkit/media/android/webmediaplayer_android.h

Issue 13688004: Location/size change notification when external rendering is enabled (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase & added a missing ifdef guard Created 7 years, 8 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: webkit/media/android/webmediaplayer_android.h
diff --git a/webkit/media/android/webmediaplayer_android.h b/webkit/media/android/webmediaplayer_android.h
index 79fa6b856611d5c2d45464e16f2fa6d15f094304..f8170dc095e88aee260336ea059a0796e2de273b 100644
--- a/webkit/media/android/webmediaplayer_android.h
+++ b/webkit/media/android/webmediaplayer_android.h
@@ -16,6 +16,7 @@
#include "third_party/WebKit/Source/Platform/chromium/public/WebSize.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebURL.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebMediaPlayer.h"
+#include "ui/gfx/rect_f.h"
#include "webkit/media/android/stream_texture_factory_android.h"
namespace webkit {
@@ -140,6 +141,13 @@ class WebMediaPlayerAndroid
// Detach the player from its manager.
void Detach();
+#if defined(GOOGLE_TV)
+ // Retrieve geometry of the media player (i.e. location and size of the video
+ // frame) if changed. Returns true only if the geometry has been changed since
+ // the last call.
+ bool RetrieveGeometryChange(gfx::RectF* rect);
+#endif
+
protected:
// Construct a WebMediaPlayerAndroid object with reference to the
// client, manager and stream texture factory.
@@ -190,8 +198,10 @@ class WebMediaPlayerAndroid
WebMediaPlayerManagerAndroid* manager() const { return manager_; }
+#if defined(GOOGLE_TV)
// Request external surface for out-of-band composition.
virtual void RequestExternalSurface() = 0;
+#endif
private:
void ReallocateVideoFrame();
@@ -266,6 +276,12 @@ class WebMediaPlayerAndroid
scoped_ptr<webkit::WebLayerImpl> video_weblayer_;
+#if defined(GOOGLE_TV)
+ // A rectangle represents the geometry of video frame, when computed last
+ // time.
+ gfx::RectF last_computed_rect_;
+#endif
+
DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerAndroid);
};
« no previous file with comments | « content/renderer/media/webmediaplayer_proxy_impl_android.cc ('k') | webkit/media/android/webmediaplayer_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698