From 1f799dfbdc345ad8a9097a1355d62868b8718cd4 Mon Sep 17 00:00:00 2001 From: Xaver Hugl Date: Mon, 9 Sep 2024 01:52:01 +0200 Subject: [PATCH] wayland/xx color management: fall back to the min. luminance of the transfer function instead of zero Assuming zero as the minimum luminance makes black point compensation not work correctly --- src/wayland/xx_colormanagement_v4.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wayland/xx_colormanagement_v4.cpp b/src/wayland/xx_colormanagement_v4.cpp index 13ec4ef326..78838f492c 100644 --- a/src/wayland/xx_colormanagement_v4.cpp +++ b/src/wayland/xx_colormanagement_v4.cpp @@ -223,7 +223,7 @@ void XXColorParametricCreatorV4::xx_image_description_creator_params_v4_create(R func.maxLuminance = m_transferFunctionLuminances->max; referenceLuminance = m_transferFunctionLuminances->reference; } - new XXImageDescriptionV4(resource->client(), image_description, resource->version(), ColorDescription(*m_colorimetry, func, referenceLuminance, m_minMasteringLuminance.value_or(0), maxFrameAverageLuminance, maxHdrLuminance, m_masteringColorimetry, Colorimetry::fromName(NamedColorimetry::BT709))); + new XXImageDescriptionV4(resource->client(), image_description, resource->version(), ColorDescription(*m_colorimetry, func, referenceLuminance, m_minMasteringLuminance.value_or(func.minLuminance), maxFrameAverageLuminance, maxHdrLuminance, m_masteringColorimetry, Colorimetry::fromName(NamedColorimetry::BT709))); wl_resource_destroy(resource->handle); }