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

Unified Diff: cc/resources/video_resource_updater.cc

Issue 12263013: media: Add support for playback of VP8 Alpha video streams (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase 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
« no previous file with comments | « no previous file | chrome/app/generated_resources.grd » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/resources/video_resource_updater.cc
diff --git a/cc/resources/video_resource_updater.cc b/cc/resources/video_resource_updater.cc
index 11bfc314d1160604a7a6f4d6f0d1cac5b6b865e5..2e68ea9228e28e10234e2302564fcc884f5be0c2 100644
--- a/cc/resources/video_resource_updater.cc
+++ b/cc/resources/video_resource_updater.cc
@@ -46,6 +46,7 @@ bool VideoResourceUpdater::VerifyFrame(
switch (video_frame->format()) {
// Acceptable inputs.
case media::VideoFrame::YV12:
+ case media::VideoFrame::YV12A:
case media::VideoFrame::YV16:
case media::VideoFrame::NATIVE_TEXTURE:
#if defined(GOOGLE_TV)
@@ -76,6 +77,7 @@ static gfx::Size SoftwarePlaneDimension(
switch (input_frame_format) {
case media::VideoFrame::YV12:
+ case media::VideoFrame::YV12A:
return gfx::ToFlooredSize(gfx::ScaleSize(coded_size, 0.5f, 0.5f));
case media::VideoFrame::YV16:
return gfx::ToFlooredSize(gfx::ScaleSize(coded_size, 0.5f, 1.f));
@@ -113,8 +115,10 @@ VideoFrameExternalResources VideoResourceUpdater::CreateForSoftwarePlanes(
// Only YUV software video frames are supported.
DCHECK(input_frame_format == media::VideoFrame::YV12 ||
+ input_frame_format == media::VideoFrame::YV12A ||
input_frame_format == media::VideoFrame::YV16);
if (input_frame_format != media::VideoFrame::YV12 &&
+ input_frame_format != media::VideoFrame::YV12A &&
input_frame_format != media::VideoFrame::YV16)
return VideoFrameExternalResources();
« no previous file with comments | « no previous file | chrome/app/generated_resources.grd » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698