drm_hwcomposer: Stop using HWC2 hooks for source crop
Add source_crop to LayerProperties and set it together with other layer
properties.
Change-Id: I2153037b6df3ad2ecf1008d8bafe09d62ef59116
Signed-off-by: Drew Davenport <ddavenport@google.com>
diff --git a/hwc2_device/HwcLayer.cpp b/hwc2_device/HwcLayer.cpp
index 2dd51ca..c972e0b 100644
--- a/hwc2_device/HwcLayer.cpp
+++ b/hwc2_device/HwcLayer.cpp
@@ -44,6 +44,9 @@
layer_data_.pi.alpha = std::lround(layer_properties.alpha.value() *
UINT16_MAX);
}
+ if (layer_properties.source_crop) {
+ layer_data_.pi.source_crop = layer_properties.source_crop.value();
+ }
}
// NOLINTNEXTLINE(readability-convert-member-functions-to-static)