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

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

Issue 2636433003: [NotForReview] Enable YUV video overlay on Skylake ChromeOS.
Patch Set: Created 3 years, 11 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 | « ui/ozone/platform/drm/common/drm_util.cc ('k') | ui/ozone/platform/drm/gpu/gbm_buffer.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 182067686831cfe8b6003bdfdccda9398089d37c..9d8a7fa2152f1c33c89d73609f2e03012b346323 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;
@@ -87,7 +88,9 @@ uint32_t FindOptimalBufferFormat(uint32_t original_format,
return DRM_FORMAT_XRGB8888;
// YUV is preferable format if supported.
- if (controller->IsFormatSupported(DRM_FORMAT_UYVY, z_order)) {
+ if (controller->IsFormatSupported(DRM_FORMAT_YUYV, z_order)) {
+ return DRM_FORMAT_YUYV;
+ } else if (controller->IsFormatSupported(DRM_FORMAT_UYVY, z_order)) {
return DRM_FORMAT_UYVY;
} else if (controller->IsFormatSupported(DRM_FORMAT_XRGB8888, z_order)) {
return DRM_FORMAT_XRGB8888;
« no previous file with comments | « ui/ozone/platform/drm/common/drm_util.cc ('k') | ui/ozone/platform/drm/gpu/gbm_buffer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698