New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 603866 link

Starred by 2 users

Issue metadata

Status: Untriaged
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 3
Type: Bug



Sign in to add a comment

Video not promoted to hardware overlay in the video player app

Project Member Reported by lionel.g...@intel.com, Apr 15 2016

Issue description

With --enable-hardware-overlays the video layers should get promoted to hardware overlays.
Unfortunately there seems to be something occluding the video when inspecting the list of quads to draw.
Turns out the shadows are overdrawn on the window's content, preventing the OverlayStrategySingleOnTop to promote the layer.

Attached a screenshot with some added debugging layer showing the shadows quads.
 
shadow-8patches.png
1.1 MB View Download
https://codereview.chromium.org/1889153002/ is an attempt at drawing 12 patches instead of 8 to prevent any overdrawing on the window's content.
shadow-12patches.png
767 KB View Download
Project Member

Comment 2 by bugdroid1@chromium.org, Apr 26 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/8b134c7492731333fabeda5e358f0604ae5f565e

commit 8b134c7492731333fabeda5e358f0604ae5f565e
Author: lionel.g.landwerlin <lionel.g.landwerlin@intel.com>
Date: Tue Apr 26 13:39:51 2016

cc: nine patch: add occlusion support

When using a NinePatchLayer to draw shadows on windows on ChromeOS part of
patches which are completely transparent are drawn on top of the window.
This prevents for example videos to be promoted into layers.

This patch introduce an optional property on the NinePatchLayer :
layer_occlusion. When this property is set, we can use it to compute 12
patches to paint the shadow rather than 8 (center omitted). This prevents
drawing on the window's content completely and allows layer promotion
algorithms to promote the windows's content as layer if possible (in
particular with videos).

BUG=603866
TEST=cc_unittests --gtest_filter=NinePatchLayer*
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel

Review URL: https://codereview.chromium.org/1889153002

Cr-Commit-Position: refs/heads/master@{#389770}

[modify] https://crrev.com/8b134c7492731333fabeda5e358f0604ae5f565e/cc/layers/nine_patch_layer.cc
[modify] https://crrev.com/8b134c7492731333fabeda5e358f0604ae5f565e/cc/layers/nine_patch_layer.h
[modify] https://crrev.com/8b134c7492731333fabeda5e358f0604ae5f565e/cc/layers/nine_patch_layer_impl.cc
[modify] https://crrev.com/8b134c7492731333fabeda5e358f0604ae5f565e/cc/layers/nine_patch_layer_impl.h
[modify] https://crrev.com/8b134c7492731333fabeda5e358f0604ae5f565e/cc/layers/nine_patch_layer_impl_unittest.cc
[modify] https://crrev.com/8b134c7492731333fabeda5e358f0604ae5f565e/mash/wm/shadow.cc
[modify] https://crrev.com/8b134c7492731333fabeda5e358f0604ae5f565e/ui/compositor/layer.cc
[modify] https://crrev.com/8b134c7492731333fabeda5e358f0604ae5f565e/ui/compositor/layer.h
[modify] https://crrev.com/8b134c7492731333fabeda5e358f0604ae5f565e/ui/wm/core/shadow.cc

Components: OS>Kernel>Video
Status: Untriaged (was: Unconfirmed)
Cc: j.iso...@samsung.com
Project Member

Comment 5 by bugdroid1@chromium.org, May 16 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/eec4f7be5b4843419b6eefe0fdf1b65cee774bc1

commit eec4f7be5b4843419b6eefe0fdf1b65cee774bc1
Author: lionel.g.landwerlin <lionel.g.landwerlin@intel.com>
Date: Mon May 16 18:46:46 2016

Revert of cc: nine patch: add occlusion support (patchset #10 id:180001 of https://codereview.chromium.org/1889153002/ )

Reason for revert:
Shadow are broken on HiDPI monitors. See https://bugs.chromium.org/p/chromium/issues/detail?id=607033

More people are noticing this and the fix is not ready yet.
Let's revert this for now.

Original issue's description:
> cc: nine patch: add occlusion support
>
> When using a NinePatchLayer to draw shadows on windows on ChromeOS part of
> patches which are completely transparent are drawn on top of the window.
> This prevents for example videos to be promoted into layers.
>
> This patch introduce an optional property on the NinePatchLayer :
> layer_occlusion. When this property is set, we can use it to compute 12
> patches to paint the shadow rather than 8 (center omitted). This prevents
> drawing on the window's content completely and allows layer promotion
> algorithms to promote the windows's content as layer if possible (in
> particular with videos).
>
> BUG=603866
> TEST=cc_unittests --gtest_filter=NinePatchLayer*
> CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel
>
> Committed: https://crrev.com/8b134c7492731333fabeda5e358f0604ae5f565e
> Cr-Commit-Position: refs/heads/master@{#389770}

TBR=aelias@chromium.org,danakj@chromium.org,derat@chromium.org,hshi@chromium.org,msw@chromium.org,sky@chromium.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=603866

Review-Url: https://codereview.chromium.org/1983803003
Cr-Commit-Position: refs/heads/master@{#393881}

[modify] https://crrev.com/eec4f7be5b4843419b6eefe0fdf1b65cee774bc1/cc/layers/nine_patch_layer.cc
[modify] https://crrev.com/eec4f7be5b4843419b6eefe0fdf1b65cee774bc1/cc/layers/nine_patch_layer.h
[modify] https://crrev.com/eec4f7be5b4843419b6eefe0fdf1b65cee774bc1/cc/layers/nine_patch_layer_impl.cc
[modify] https://crrev.com/eec4f7be5b4843419b6eefe0fdf1b65cee774bc1/cc/layers/nine_patch_layer_impl.h
[modify] https://crrev.com/eec4f7be5b4843419b6eefe0fdf1b65cee774bc1/cc/layers/nine_patch_layer_impl_unittest.cc
[modify] https://crrev.com/eec4f7be5b4843419b6eefe0fdf1b65cee774bc1/mash/wm/shadow.cc
[modify] https://crrev.com/eec4f7be5b4843419b6eefe0fdf1b65cee774bc1/ui/compositor/layer.cc
[modify] https://crrev.com/eec4f7be5b4843419b6eefe0fdf1b65cee774bc1/ui/compositor/layer.h
[modify] https://crrev.com/eec4f7be5b4843419b6eefe0fdf1b65cee774bc1/ui/wm/core/shadow.cc

Project Member

Comment 6 by bugdroid1@chromium.org, Jul 27 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/258c7d3e78c8f4b2b96c5ade9cddb2d0b1cbfdca

commit 258c7d3e78c8f4b2b96c5ade9cddb2d0b1cbfdca
Author: lionel.g.landwerlin <lionel.g.landwerlin@intel.com>
Date: Wed Jul 27 09:55:24 2016

cc: nine patch: add occlusion support

Reland of https://codereview.chromium.org/1983803003 with fix for
hidpi screens

When using a NinePatchLayer to draw shadows on windows on ChromeOS
part of patches which are completely transparent are drawn on top of
the window. This prevents for example videos to be promoted into
layers.

This patch introduce an optional property on the NinePatchLayer :
layer_occlusion. When this property is set, we can use it to compute
12 patches to paint the shadow rather than 8 (center omitted). This
prevents drawing on the window's content completely and allows layer
promotion algorithms to promote the windows's content as layer if
possible (in particular with videos).

BUG=603866
TEST=cc_unittests --gtest_filter=NinePatchLayer*
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel

Review-Url: https://codereview.chromium.org/2083083004
Cr-Commit-Position: refs/heads/master@{#408084}

[modify] https://crrev.com/258c7d3e78c8f4b2b96c5ade9cddb2d0b1cbfdca/ash/mus/shadow.cc
[modify] https://crrev.com/258c7d3e78c8f4b2b96c5ade9cddb2d0b1cbfdca/cc/layers/nine_patch_layer.cc
[modify] https://crrev.com/258c7d3e78c8f4b2b96c5ade9cddb2d0b1cbfdca/cc/layers/nine_patch_layer.h
[modify] https://crrev.com/258c7d3e78c8f4b2b96c5ade9cddb2d0b1cbfdca/cc/layers/nine_patch_layer_impl.cc
[modify] https://crrev.com/258c7d3e78c8f4b2b96c5ade9cddb2d0b1cbfdca/cc/layers/nine_patch_layer_impl.h
[modify] https://crrev.com/258c7d3e78c8f4b2b96c5ade9cddb2d0b1cbfdca/cc/layers/nine_patch_layer_impl_unittest.cc
[modify] https://crrev.com/258c7d3e78c8f4b2b96c5ade9cddb2d0b1cbfdca/ui/compositor/layer.cc
[modify] https://crrev.com/258c7d3e78c8f4b2b96c5ade9cddb2d0b1cbfdca/ui/compositor/layer.h
[modify] https://crrev.com/258c7d3e78c8f4b2b96c5ade9cddb2d0b1cbfdca/ui/wm/core/shadow.cc

Status: Archived (was: Untriaged)

Comment 8 by ketakid@google.com, Mar 18 2017

Status: Available (was: Archived)
Activating. Please assign to the right owner and the appropriate priority.
Project Member

Comment 9 by sheriffbot@chromium.org, Apr 13 2018

Labels: Hotlist-Recharge-Cold
Status: Untriaged (was: Available)
This issue has been Available for over a year. If it's no longer important or seems unlikely to be fixed, please consider closing it out. If it is important, please re-triage the issue.

Sorry for the inconvenience if the bug really should have been left as Available.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot

Sign in to add a comment