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

Unified Diff: ui/ozone/platform/drm/test/mock_drm_device.cc

Issue 1314553002: Move Format checks to HardwareDisplayPlane (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Review fixes Created 5 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 | « ui/ozone/platform/drm/gpu/scanout_buffer.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/ozone/platform/drm/test/mock_drm_device.cc
diff --git a/ui/ozone/platform/drm/test/mock_drm_device.cc b/ui/ozone/platform/drm/test/mock_drm_device.cc
index c72f82a2fb633cf6f38d5656e6cd9254a72bc409..8d09356d81caeb1ef206ccfd8d86064725023992 100644
--- a/ui/ozone/platform/drm/test/mock_drm_device.cc
+++ b/ui/ozone/platform/drm/test/mock_drm_device.cc
@@ -4,6 +4,7 @@
#include "ui/ozone/platform/drm/test/mock_drm_device.h"
+#include <drm_fourcc.h>
#include <xf86drm.h>
#include <xf86drmMode.h>
@@ -31,8 +32,12 @@ class MockHardwareDisplayPlaneManager
crtcs_.swap(crtcs);
for (size_t crtc_idx = 0; crtc_idx < crtcs_.size(); crtc_idx++) {
for (size_t i = 0; i < planes_per_crtc; i++) {
- planes_.push_back(
+ scoped_ptr<HardwareDisplayPlane> plane(
new HardwareDisplayPlane(kPlaneBaseId + i, 1 << crtc_idx));
+ // Add support to test more formats.
+ plane->Initialize(drm, std::vector<uint32_t>(1, DRM_FORMAT_XRGB8888),
+ false, true);
+ planes_.push_back(plane.Pass());
}
}
}
« no previous file with comments | « ui/ozone/platform/drm/gpu/scanout_buffer.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698