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

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

Issue 2686903003: ozone: prefer YUYV format for overlay.
Patch Set: Created 3 years, 10 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 | ui/ozone/platform/drm/gpu/drm_overlay_validator_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/ozone/platform/drm/gpu/drm_overlay_validator.cc
diff --git a/ui/ozone/platform/drm/gpu/drm_overlay_validator.cc b/ui/ozone/platform/drm/gpu/drm_overlay_validator.cc
index e83d62e6070314de5812d5d556406189c9ed3ad4..76ae574ca241ab1ad6f0e2365c421a91c8ee8a33 100644
--- a/ui/ozone/platform/drm/gpu/drm_overlay_validator.cc
+++ b/ui/ozone/platform/drm/gpu/drm_overlay_validator.cc
@@ -23,6 +23,7 @@ bool NeedsAlphaComposition(uint32_t format) {
switch (format) {
case DRM_FORMAT_XRGB8888:
case DRM_FORMAT_UYVY:
+ case DRM_FORMAT_YUYV:
return false;
default:
return true;
@@ -77,8 +78,8 @@ uint32_t FindOptimalBufferFormat(uint32_t original_format,
}
// YUV is preferable format if supported.
- if (controller->IsFormatSupported(DRM_FORMAT_UYVY, z_order)) {
- return DRM_FORMAT_UYVY;
+ if (controller->IsFormatSupported(DRM_FORMAT_YUYV, z_order)) {
+ return DRM_FORMAT_YUYV;
} else if (controller->IsFormatSupported(DRM_FORMAT_XRGB8888, z_order)) {
return DRM_FORMAT_XRGB8888;
}
« no previous file with comments | « no previous file | ui/ozone/platform/drm/gpu/drm_overlay_validator_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698