diff options
author | halliwell <halliwell@chromium.org> | 2015-05-13 09:27:21 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-05-13 16:27:32 +0000 |
commit | 9e2b43aee24f3a9827e05d34578ba9a747236cd5 (patch) | |
tree | 5e0aebdd03bd476c7f67f98c6b07b96ab6d03a64 /cc/trees | |
parent | 4a44a2b9ce220eb5b7f82018a5d3df06d81807d2 (diff) | |
download | chromium_src-9e2b43aee24f3a9827e05d34578ba9a747236cd5.zip chromium_src-9e2b43aee24f3a9827e05d34578ba9a747236cd5.tar.gz chromium_src-9e2b43aee24f3a9827e05d34578ba9a747236cd5.tar.bz2 |
Add distinction between RGB and RGBA native texture video frame and resources
Currently it's impossible to place a NATIVE_TEXTURE VideoFrame into an
overlay, because:
* NATIVE_TEXTURE VideoFrame turns into RGB_RESOURCE in
VideoResourceUpdater
* RGB_RESOURCE always sets premultipled_alpha flag on its
TextureDrawQuad (see VideoLayerImpl::AppendQuads)
* OverlayStrategyCommon rejects quads with premultiplied alpha
BUG=
Review URL: https://codereview.chromium.org/1134643002
Cr-Commit-Position: refs/heads/master@{#329651}
Diffstat (limited to 'cc/trees')
-rw-r--r-- | cc/trees/layer_tree_host_unittest_context.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/cc/trees/layer_tree_host_unittest_context.cc b/cc/trees/layer_tree_host_unittest_context.cc index c1436e5..71c9ea0 100644 --- a/cc/trees/layer_tree_host_unittest_context.cc +++ b/cc/trees/layer_tree_host_unittest_context.cc @@ -1078,11 +1078,13 @@ class LayerTreeHostContextTestDontUseLostResources hw_video_frame_ = VideoFrame::WrapNativeTexture( gpu::MailboxHolder(mailbox, GL_TEXTURE_2D, sync_point), media::VideoFrame::ReleaseMailboxCB(), gfx::Size(4, 4), - gfx::Rect(0, 0, 4, 4), gfx::Size(4, 4), base::TimeDelta(), false); + gfx::Rect(0, 0, 4, 4), gfx::Size(4, 4), base::TimeDelta(), + false /* allow_overlay */, true /* has_alpha */); scaled_hw_video_frame_ = VideoFrame::WrapNativeTexture( gpu::MailboxHolder(mailbox, GL_TEXTURE_2D, sync_point), media::VideoFrame::ReleaseMailboxCB(), gfx::Size(4, 4), - gfx::Rect(0, 0, 3, 2), gfx::Size(4, 4), base::TimeDelta(), false); + gfx::Rect(0, 0, 3, 2), gfx::Size(4, 4), base::TimeDelta(), + false /* allow_overlay */, true /* has_alpha */); color_frame_provider_.set_frame(color_video_frame_); hw_frame_provider_.set_frame(hw_video_frame_); |