From 37f48a200ecce78e0c28de99ab0939b87a2ef9f1 Mon Sep 17 00:00:00 2001 From: David Turner Date: Thu, 8 May 2025 11:16:19 +0100 Subject: [PATCH] render/vulkan: Use BT.709 for YUV conversion Change from BT.601 to BT.709 color encoding for YUV conversion in the vulkan renderer. This is to be consistent with the gles2 renderer as well as the DRM scanout path. The latter is important to avoid visible color shifts when direct scanout is enabled/disabled. --- render/vulkan/renderer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/render/vulkan/renderer.c b/render/vulkan/renderer.c index b2feca013..3cca5d6f5 100644 --- a/render/vulkan/renderer.c +++ b/render/vulkan/renderer.c @@ -1956,7 +1956,7 @@ struct wlr_vk_pipeline_layout *get_or_create_pipeline_layout( VkSamplerYcbcrConversionCreateInfo conversion_create_info = { .sType = VK_STRUCTURE_TYPE_SAMPLER_YCBCR_CONVERSION_CREATE_INFO, .format = key->ycbcr_format->vk, - .ycbcrModel = VK_SAMPLER_YCBCR_MODEL_CONVERSION_YCBCR_601, + .ycbcrModel = VK_SAMPLER_YCBCR_MODEL_CONVERSION_YCBCR_709, .ycbcrRange = VK_SAMPLER_YCBCR_RANGE_ITU_NARROW, .xChromaOffset = VK_CHROMA_LOCATION_MIDPOINT, .yChromaOffset = VK_CHROMA_LOCATION_MIDPOINT,