From 02d8fa593b45390a72d1bc43bc5ddb46d7ee469f Mon Sep 17 00:00:00 2001 From: Philip Rebohle Date: Thu, 15 Aug 2024 21:57:23 +0200 Subject: [PATCH] [dxgi] Change reported UMD driver version Fixes a potential crash in Hunt Showdown. --- src/dxgi/dxgi_adapter.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/dxgi/dxgi_adapter.cpp b/src/dxgi/dxgi_adapter.cpp index b6bfe61e9..6b82a661a 100644 --- a/src/dxgi/dxgi_adapter.cpp +++ b/src/dxgi/dxgi_adapter.cpp @@ -127,10 +127,13 @@ namespace dxvk { || InterfaceName == __uuidof(ID3D10Device1)) hr = S_OK; - // We can't really reconstruct the version numbers - // returned by Windows drivers from Vulkan data - if (SUCCEEDED(hr) && pUMDVersion) - pUMDVersion->QuadPart = INT64_MAX; + // Windows drivers return something along the lines of 32.0.xxxxx.yyyy, + // so just be conservative here and return a high number. We cannot + // reconstruct meaningful UMD versions from Vulkan driver versions. + if (SUCCEEDED(hr) && pUMDVersion) { + pUMDVersion->HighPart = 0x00200000u; + pUMDVersion->LowPart = 0xffffffffu; + } if (FAILED(hr)) { Logger::err("DXGI: CheckInterfaceSupport: Unsupported interface");