Chromium Code Reviews| Index: content/renderer/media/android/webmediaplayer_android.h |
| diff --git a/content/renderer/media/android/webmediaplayer_android.h b/content/renderer/media/android/webmediaplayer_android.h |
| index 44784f121925fe9eb42d5279de3af6308f45bd3b..1205a10a00b12eb9c188c6a86e768365a0a6995b 100644 |
| --- a/content/renderer/media/android/webmediaplayer_android.h |
| +++ b/content/renderer/media/android/webmediaplayer_android.h |
| @@ -29,6 +29,9 @@ |
| #include "third_party/WebKit/public/platform/WebMediaPlayer.h" |
| #include "third_party/WebKit/public/platform/WebSize.h" |
| #include "third_party/WebKit/public/platform/WebURL.h" |
| +#include "third_party/skia/include/core/SkBitmap.h" |
| +#include "third_party/skia/include/gpu/GrContext.h" |
| +#include "third_party/skia/include/gpu/SkGrPixelRef.h" |
| #include "ui/gfx/rect_f.h" |
| namespace base { |
| @@ -102,6 +105,9 @@ class WebMediaPlayerAndroid : public blink::WebMediaPlayer, |
| // Poster image, as defined in the <video> element. |
| virtual void setPoster(const blink::WebURL& poster) OVERRIDE; |
| + // FIXME: This path "only works" on Android. It is a workaround for the problem that Skia could not handle Android's GL_TEXTURE_EXTERNAL_OES |
| + // texture internally. It should be removed and replaced by the normal paint path. |
| + // https://code.google.com/p/skia/issues/detail?id=1189 |
| // Methods for painting. |
| virtual void paint(blink::WebCanvas* canvas, |
| const blink::WebRect& rect, |
| @@ -276,6 +282,8 @@ class WebMediaPlayerAndroid : public blink::WebMediaPlayer, |
| // NULL immediately and reset. |
| void SetDecryptorReadyCB(const media::DecryptorReadyCB& decryptor_ready_cb); |
| + bool ensureTextureBackedSkBitmap(GrContext* gr, SkBitmap& bitmap, const blink::WebSize& size, GrSurfaceOrigin origin, GrPixelConfig config); |
|
qinmin
2014/07/25 17:01:10
s/ensure/Ensure/
Srirama
2014/07/25 18:06:29
Done.
|
| + |
| blink::WebFrame* const frame_; |
| blink::WebMediaPlayerClient* const client_; |
| @@ -442,6 +450,8 @@ class WebMediaPlayerAndroid : public blink::WebMediaPlayer, |
| // player_manager_->SetCdm() directly. |
| media::DecryptorReadyCB decryptor_ready_cb_; |
| + SkBitmap m_bitmap; |
|
qinmin
2014/07/25 17:01:10
chromium doesn't use this naming scheme, use bitma
Srirama
2014/07/25 18:06:29
Done. Changed name to bitmap_ and regarding whethe
|
| + |
| // NOTE: Weak pointers must be invalidated before all other member variables. |
| base::WeakPtrFactory<WebMediaPlayerAndroid> weak_factory_; |