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

Unified Diff: content/renderer/media/android/webmediaplayer_android.h

Issue 445013002: media: Optimize HW Video to 2D Canvas copy. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase to ToT. Address nits Created 6 years, 2 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: 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 c06eac05ee7df24f38724ffc692f5ea5abcf98d7..79d0f50788d41259c0c935fcfa38e3a9bc9fc3e9 100644
--- a/content/renderer/media/android/webmediaplayer_android.h
+++ b/content/renderer/media/android/webmediaplayer_android.h
@@ -28,13 +28,10 @@
#include "media/base/demuxer_stream.h"
#include "media/base/media_keys.h"
#include "media/base/time_delta_interpolator.h"
-#include "third_party/WebKit/public/platform/WebGraphicsContext3D.h"
+#include "media/filters/skcanvas_video_renderer.h"
#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 {
@@ -45,6 +42,7 @@ namespace blink {
class WebContentDecryptionModule;
class WebContentDecryptionModuleResult;
class WebFrame;
+class WebGraphicsContext3D;
class WebURL;
}
@@ -118,10 +116,6 @@ class WebMediaPlayerAndroid : public blink::WebMediaPlayer,
virtual void setPoster(const blink::WebURL& poster) override;
// Methods for painting.
- // FIXME: This path "only works" on Android. It is a workaround for the
- // issue 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
dshwang 2014/10/13 17:07:42 Remove the stale comment. Currently, blink uses We
virtual void paint(blink::WebCanvas* canvas,
const blink::WebRect& rect,
unsigned char alpha,
@@ -326,11 +320,6 @@ class WebMediaPlayerAndroid : public blink::WebMediaPlayer,
blink::WebContentDecryptionModuleResult result,
bool success);
- bool EnsureTextureBackedSkBitmap(GrContext* gr, SkBitmap& bitmap,
- const blink::WebSize& size,
- GrSurfaceOrigin origin,
- GrPixelConfig config);
-
bool IsHLSStream() const;
blink::WebFrame* const frame_;
@@ -487,7 +476,7 @@ class WebMediaPlayerAndroid : public blink::WebMediaPlayer,
// player_manager_->SetCdm() directly.
media::DecryptorReadyCB decryptor_ready_cb_;
- SkBitmap bitmap_;
+ media::SkCanvasVideoRenderer skcanvas_video_renderer_;
// Whether stored credentials are allowed to be passed to the server.
bool allow_stored_credentials_;

Powered by Google App Engine
This is Rietveld 408576698