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

Unified Diff: cc/layers/video_layer_impl.cc

Issue 1134643002: Add distinction between RGB and RGBA native texture video frames and resources (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix unit test breakage from bad merge Created 5 years, 7 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 | cc/resources/video_resource_updater.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layers/video_layer_impl.cc
diff --git a/cc/layers/video_layer_impl.cc b/cc/layers/video_layer_impl.cc
index 6f72b01fe83c18903923e67bbaa7f34eff27d77e..ae028d5552e4462c4fb0cf44e53e2b6f6aaefc82 100644
--- a/cc/layers/video_layer_impl.cc
+++ b/cc/layers/video_layer_impl.cc
@@ -261,11 +261,13 @@ void VideoLayerImpl::AppendQuads(RenderPass* render_pass,
ValidateQuadResources(yuv_video_quad);
break;
}
+ case VideoFrameExternalResources::RGBA_RESOURCE:
case VideoFrameExternalResources::RGB_RESOURCE: {
DCHECK_EQ(frame_resources_.size(), 1u);
if (frame_resources_.size() < 1u)
break;
- bool premultiplied_alpha = true;
+ bool premultiplied_alpha =
+ (frame_resource_type_ == VideoFrameExternalResources::RGBA_RESOURCE);
gfx::PointF uv_top_left(0.f, 0.f);
gfx::PointF uv_bottom_right(tex_width_scale, tex_height_scale);
float opacity[] = {1.0f, 1.0f, 1.0f, 1.0f};
« no previous file with comments | « no previous file | cc/resources/video_resource_updater.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698