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

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

Issue 2951193002: ozone/drm: Only reuse ScanoutBuffers with compatible modifiers (Closed)
Patch Set: Created 3 years, 6 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/gpu/gbm_buffer_base.cc ('k') | ui/ozone/platform/drm/gpu/mock_scanout_buffer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/ozone/platform/drm/gpu/mock_hardware_display_plane_manager.cc
diff --git a/ui/ozone/platform/drm/gpu/mock_hardware_display_plane_manager.cc b/ui/ozone/platform/drm/gpu/mock_hardware_display_plane_manager.cc
index 409ac445565a88d58b3c51448ed64cf408d00953..ec26ff89a1110f9e5fc3238c695a272a0b4b63ea 100644
--- a/ui/ozone/platform/drm/gpu/mock_hardware_display_plane_manager.cc
+++ b/ui/ozone/platform/drm/gpu/mock_hardware_display_plane_manager.cc
@@ -18,6 +18,7 @@ MockHardwareDisplayPlaneManager::MockHardwareDisplayPlaneManager(
const std::vector<uint32_t>& crtcs,
uint32_t planes_per_crtc) {
const int kPlaneBaseId = 50;
+ const struct drm_format_modifier linear_modifier { 0x1, DRM_FORMAT_MOD_NONE };
drm_ = drm;
crtcs_ = crtcs;
for (size_t crtc_idx = 0; crtc_idx < crtcs_.size(); crtc_idx++) {
@@ -25,7 +26,7 @@ MockHardwareDisplayPlaneManager::MockHardwareDisplayPlaneManager(
std::unique_ptr<HardwareDisplayPlane> plane(
new HardwareDisplayPlane(kPlaneBaseId + i, 1 << crtc_idx));
plane->Initialize(drm, std::vector<uint32_t>(1, DRM_FORMAT_XRGB8888),
- std::vector<drm_format_modifier>(), // modifiers
+ std::vector<drm_format_modifier>(1, linear_modifier),
false, true);
planes_.push_back(std::move(plane));
}
« no previous file with comments | « ui/ozone/platform/drm/gpu/gbm_buffer_base.cc ('k') | ui/ozone/platform/drm/gpu/mock_scanout_buffer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698