From 38cd2f729051d8565b79c9004b2e089a25048637 Mon Sep 17 00:00:00 2001 From: Joshua Ashton Date: Sat, 20 Aug 2022 23:54:36 +0000 Subject: [PATCH] [dxvk] Remove WIN32 check for handle type in DxvkFenceCreateInfo On other platforms we always have a HANDLE and will return through a HANDLE anyway. When we implement this on Linux, we can just add an `int fd` to the union and it can use that, and return it out as a HANDLE. --- src/dxvk/dxvk_fence.h | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/dxvk/dxvk_fence.h b/src/dxvk/dxvk_fence.h index 797452860..0c6693693 100644 --- a/src/dxvk/dxvk_fence.h +++ b/src/dxvk/dxvk_fence.h @@ -23,12 +23,9 @@ namespace dxvk { uint64_t initialValue; VkExternalSemaphoreHandleTypeFlagBits sharedType = VK_EXTERNAL_SEMAPHORE_HANDLE_TYPE_FLAG_BITS_MAX_ENUM; union { -#ifdef _WIN32 + // When we want to implement this on non-Windows platforms, + // we could add a `int fd` here, etc. HANDLE sharedHandle = INVALID_HANDLE_VALUE; -#else - // Placeholder for other handle types, such as FD - void *dummy; -#endif }; };