drm_hwcomposer: Create intermediate enum for colorspace and samplerange
Part of "frontend" isolation activities.
Also allows to additionally simplify atomic commit.
Signed-off-by: Roman Stratiienko <roman.o.stratiienko@globallogic.com>
diff --git a/include/drmhwcomposer.h b/include/drmhwcomposer.h
index 22af12b..8abf840 100644
--- a/include/drmhwcomposer.h
+++ b/include/drmhwcomposer.h
@@ -32,6 +32,19 @@
class DrmFbIdHandle;
+enum class DrmHwcColorSpace : int32_t {
+ kUndefined,
+ kItuRec601,
+ kItuRec709,
+ kItuRec2020,
+};
+
+enum class DrmHwcSampleRange : int32_t {
+ kUndefined,
+ kFullRange,
+ kLimitedRange,
+};
+
enum DrmHwcTransform {
kIdentity = 0,
kFlipH = 1 << 0,
@@ -58,7 +71,8 @@
uint16_t alpha = 0xffff;
hwc_frect_t source_crop;
hwc_rect_t display_frame;
- android_dataspace_t dataspace;
+ DrmHwcColorSpace color_space;
+ DrmHwcSampleRange sample_range;
UniqueFd acquire_fence;