[RFC v4 17/22] drm-uapi: Add custom 1D LUT
Bhanuprakash Modem
bhanuprakash.modem at intel.com
Wed Feb 14 06:39:48 UTC 2024
Signed-off-by: Bhanuprakash Modem <bhanuprakash.modem at intel.com>
---
include/drm-uapi/drm_mode.h | 29 +++++++++++++++++++++++++++++
1 file changed, 29 insertions(+)
diff --git a/include/drm-uapi/drm_mode.h b/include/drm-uapi/drm_mode.h
index 476c1a7be..7def05fe8 100644
--- a/include/drm-uapi/drm_mode.h
+++ b/include/drm-uapi/drm_mode.h
@@ -874,8 +874,37 @@ struct drm_color_lut {
__u16 reserved;
};
+/*
+ * Creating 64 bit palette entries for better data
+ * precision. This will be required for HDR and
+ * similar color processing usecases.
+ */
+struct drm_color_lut_ext {
+ /*
+ * Data is U32.32 fixed point format.
+ */
+ __u64 red;
+ __u64 green;
+ __u64 blue;
+ __u64 reserved;
+};
+
+struct drm_color_lut_range {
+ /* DRM_MODE_LUT_* */
+ __u32 flags;
+ /* number of points on the curve */
+ __u16 count;
+ /* input/output bits per component */
+ __u8 input_bpc, output_bpc;
+ /* input start/end values */
+ __s32 start, end;
+ /* output min/max values */
+ __s32 min, max;
+};
+
enum drm_colorop_type {
DRM_COLOROP_1D_CURVE,
+ DRM_COLOROP_1D_LUT,
DRM_COLOROP_CTM_3X3,
DRM_COLOROP_CTM_3X4,
};
--
2.43.0
More information about the igt-dev
mailing list