drm_hwcomposer: Add DrmMode::SameSize
Helper function to check if two modes have the same size by comparing
the vdisplay and hdisplay of the underlying drmModeModeInfo.
Change-Id: Idb1923e6f7ff42d886f9e851e15fdac99af54fb9
Signed-off-by: Drew Davenport <ddavenport@google.com>
diff --git a/drm/DrmMode.h b/drm/DrmMode.h
index 5450daf..7520824 100644
--- a/drm/DrmMode.h
+++ b/drm/DrmMode.h
@@ -35,6 +35,8 @@
bool operator==(const drmModeModeInfo &m) const;
+ bool SameSize(const DrmMode &mode) const;
+
auto &GetRawMode() const {
return mode_;
}