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

Unified Diff: ui/ozone/platform/drm/gpu/hardware_display_plane_manager.cc

Issue 2254103002: ozone: Allow full screen overlay optimization for BGR formats. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove "only" in the comment. Created 4 years, 4 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/ozone/platform/drm/gpu/hardware_display_plane_manager.cc
diff --git a/ui/ozone/platform/drm/gpu/hardware_display_plane_manager.cc b/ui/ozone/platform/drm/gpu/hardware_display_plane_manager.cc
index 6bac1893128b35c01fe0dfa2b359b0e8096ead0f..3f6f864f34c19a20208f998a58ce3a418d6ce318 100644
--- a/ui/ozone/platform/drm/gpu/hardware_display_plane_manager.cc
+++ b/ui/ozone/platform/drm/gpu/hardware_display_plane_manager.cc
@@ -266,9 +266,16 @@ bool HardwareDisplayPlaneManager::AssignOverlayPlanes(
if (primary_plane) {
// TODO(dcastagna): Check if we can move this optimization to
// GLRenderer::ScheduleOverlays.
- // Note that Chromium compositor promotes buffers to overlays (ARGB
+ // Note that Chromium compositor promotes buffers to overlays (ABGR
// ones too) only if blending is not needed.
- if ((fourcc_format == DRM_FORMAT_XRGB8888 ||
+ // TODO(dcastagna): this should check if the format is the same as
+ // primary_plane->format minus alpha. Changing the format of the primary
+ // plane currently works on rockchip with 3.14 kernel and won't work with
kalyank 2016/08/18 17:23:10 Ideally what we want is if Kernel/hardware can swa
Daniele Castagna 2016/08/18 22:34:34 AFAIK there is no interface from the kernel to kno
+ // newer kernels. Remove this hack as soon as we can switch the primary
+ // plane format to match overlay buffers formats.
+ if ((fourcc_format == DRM_FORMAT_XBGR8888 ||
+ fourcc_format == DRM_FORMAT_ABGR8888 ||
+ fourcc_format == DRM_FORMAT_XRGB8888 ||
fourcc_format == DRM_FORMAT_ARGB8888) &&
primary_display_bounds == plane.display_bounds) {
ResetCurrentPlaneList(plane_list);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698