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

Unified Diff: cc/resources/video_resource_updater.cc

Issue 13886011: media: Add support for playback of VP8 Alpha video streams (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
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 a50e4c8b03b5722fc77b14247f6e1c8d5b8f1193..9aa3644f1744699c694928c506c945d097fe5941 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