Skip to content

Commit 284f153

Browse files
committed
Fix typo of RGB_STUDIO vs RGB_FULL in DXGI interop.
1 parent 7b07e56 commit 284f153

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

vulkan/wsi_dxgi.cpp

+3-3
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,7 @@ static DXGI_COLOR_SPACE_TYPE convert_vk_color_space(VkColorSpaceKHR colspace)
212212
case VK_COLOR_SPACE_HDR10_ST2084_EXT:
213213
return DXGI_COLOR_SPACE_RGB_FULL_G2084_NONE_P2020;
214214
case VK_COLOR_SPACE_SRGB_NONLINEAR_KHR:
215-
return DXGI_COLOR_SPACE_RGB_STUDIO_G22_NONE_P709;
215+
return DXGI_COLOR_SPACE_RGB_FULL_G22_NONE_P709;
216216
default:
217217
return DXGI_COLOR_SPACE_RESERVED;
218218
}
@@ -371,15 +371,15 @@ bool DXGIInteropSwapchain::init_swapchain(HWND hwnd_, VkSurfaceFormatKHR format,
371371
((space_support & DXGI_SWAP_CHAIN_COLOR_SPACE_SUPPORT_FLAG_PRESENT) == 0))
372372
{
373373
// Fallback to SDR if HDR doesn't pass check.
374-
if (FAILED(swapchain->CheckColorSpaceSupport(DXGI_COLOR_SPACE_RGB_STUDIO_G22_NONE_P709, &space_support)) ||
374+
if (FAILED(swapchain->CheckColorSpaceSupport(DXGI_COLOR_SPACE_RGB_FULL_G22_NONE_P709, &space_support)) ||
375375
((space_support & DXGI_SWAP_CHAIN_COLOR_SPACE_SUPPORT_FLAG_PRESENT) == 0))
376376
{
377377
return false;
378378
}
379379

380380
LOGW("HDR10 not supported by DXGI swapchain, falling back to SDR.\n");
381381
surface_format.colorSpace = VK_COLOR_SPACE_SRGB_NONLINEAR_KHR;
382-
color_space = DXGI_COLOR_SPACE_RGB_STUDIO_G22_NONE_P709;
382+
color_space = DXGI_COLOR_SPACE_RGB_FULL_G22_NONE_P709;
383383
}
384384

385385
if (FAILED(swapchain->SetColorSpace1(color_space)))

0 commit comments

Comments
 (0)