HW overlays in portrait mode are upside down |
||||||||
Issue descriptionTo reproduce: crosvideo.appspot.com, play a video, maximize to fullscreen, put eve or soraka in tablet/portrait mode. Can this be in any way related to the work we've been doing for flipping upside down webgl/canvas?
,
Aug 9
,
Aug 10
,
Aug 10
dcastagna@chromium.org: who is doing Q/A on ChromeOS side? It seems we might be able to bisect and pin-point when this regress, so maybe assign a Q/A folk to own this bug?
,
Aug 10
back at M68 it is still upside down with underlays (single-on-top isn't kicking in for the rotated image) It may go back before that. It shows for both underlay and single-on-top.
,
Aug 10
Here is a thought. In the kernel, for the primary plane, there is a swap of DRM_ROTATE_90 for PLANE_CTL_ROTATE_270 and DRM_ROTATE_270 for PLANE_CTL_ROTATE_90. This occurs in skl_plane_ctl_rotation[1]. This is only done for the primary plane. The sprite planes (which the underlay/overlay (NV12) video is), do not go through this path. I can go into OverlayTransformToDrmRotationPropertyValue[2] and make this switch happen. OVERLAY_TRANSFORM_ROTATE_90 maps to DRM_ROTATE_270 and OVERLAY_TRANSFORM_ROTATE_270 maps to DRM_ROTATE_90. And then the video rotates correctly. [1]: https://chromium.googlesource.com/chromiumos/third_party/kernel/+/factory-soraka-10323.39.B-chromeos-4.4/drivers/gpu/drm/i915/intel_display.c#3505 [2]: https://cs.chromium.org/chromium/src/ui/ozone/platform/drm/gpu/hardware_display_plane_atomic.cc?q=OverlayTransformToDrmRotationPropertyValue&g=0&l=24
,
Aug 17
,
Aug 24
Any progress on this?
,
Aug 24
drm rotation is ccw, this seems to be backwards from chrome rotation. I think the solution is to change the mapping of DRM_ROTATE to OVERLAY_TRANSFORM_ROTATE in hardware_display_plane_atomic.cc but I haven't confirmed what the direction of OVERLAY_TRANSFORM_ROTATE is at the moment
,
Aug 30
The solution for now is to reject rotated NV12 planes. Only tiled NV12 planes can be rotated by DRM. Software video decoders currently use non-tiled NV12 planes. There isn't a good mechanism to get back the necessary information from atomic test.
,
Sep 5
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/a90551a9a54efe3afdecb37b450a0cd56dad6ac1 commit a90551a9a54efe3afdecb37b450a0cd56dad6ac1 Author: Fritz Koenig <frkoenig@chromium.org> Date: Wed Sep 05 17:11:57 2018 ozone/drm: Turn off unsupported overlay rotations DRM does not support overlay rotation well. NV12 planes are supported, but they need to be tiled. That information is not available currently. BUG= 872901 TEST=browser Change-Id: Ide9c837dca62a6db9d13e6fedaaf5b256e4bcb79 Reviewed-on: https://chromium-review.googlesource.com/1196019 Commit-Queue: Fritz Koenig <frkoenig@chromium.org> Reviewed-by: Daniele Castagna <dcastagna@chromium.org> Reviewed-by: Daniel Nicoara <dnicoara@chromium.org> Cr-Commit-Position: refs/heads/master@{#588903} [modify] https://crrev.com/a90551a9a54efe3afdecb37b450a0cd56dad6ac1/ui/ozone/platform/drm/gpu/hardware_display_plane_atomic.cc
,
Sep 7
Confirmed working in R71-11043.0.0 on soraka
,
Sep 7
,
Sep 7
,
Sep 7
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/80ab9a03ccc6ecb0d28636b3dafc1296518ffac6 commit 80ab9a03ccc6ecb0d28636b3dafc1296518ffac6 Author: Fritz Koenig <frkoenig@chromium.org> Date: Fri Sep 07 22:45:16 2018 ozone/drm: Turn off unsupported overlay rotations DRM does not support overlay rotation well. NV12 planes are supported, but they need to be tiled. That information is not available currently. BUG= 872901 TEST=browser (cherry picked from commit a90551a9a54efe3afdecb37b450a0cd56dad6ac1) Change-Id: Ide9c837dca62a6db9d13e6fedaaf5b256e4bcb79 Reviewed-on: https://chromium-review.googlesource.com/1196019 Commit-Queue: Fritz Koenig <frkoenig@chromium.org> Reviewed-by: Daniele Castagna <dcastagna@chromium.org> Reviewed-by: Daniel Nicoara <dnicoara@chromium.org> Cr-Original-Commit-Position: refs/heads/master@{#588903} Reviewed-on: https://chromium-review.googlesource.com/1214403 Cr-Commit-Position: refs/branch-heads/3538@{#174} Cr-Branched-From: 79f7c91a2b2a2932cd447fa6f865cb6662fa8fa6-refs/heads/master@{#587811} [modify] https://crrev.com/80ab9a03ccc6ecb0d28636b3dafc1296518ffac6/ui/ozone/platform/drm/gpu/hardware_display_plane_atomic.cc
,
Sep 10
|
||||||||
►
Sign in to add a comment |
||||||||
Comment 1 by frkoenig@chromium.org
, Aug 9