Skip to content

Commit 2fc4bcf

Browse files
committed
Add option to disable DXGI interop.
1 parent cc02d39 commit 2fc4bcf

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

CMakeLists.txt

+1
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ option(GRANITE_VULKAN_SPIRV_CROSS "Add reflection support to Vulkan backend." ON
3535
option(GRANITE_VULKAN_SHADER_MANAGER_RUNTIME_COMPILER "Enable Vulkan GLSL runtime compiler." ON)
3636
option(GRANITE_VULKAN_FOSSILIZE "Enable support for Fossilize." ON)
3737
option(GRANITE_VULKAN_PROFILES "Enable profiles support." OFF)
38+
option(GRANITE_VULKAN_DXGI_INTEROP "Enable DXGI interop when running on Windows." ON)
3839
option(GRANITE_AUDIO "Enable Audio support." OFF)
3940
option(GRANITE_PLATFORM "Granite Platform" "SDL")
4041
option(GRANITE_HIDDEN "Declare symbols as hidden by default. Useful if you build Granite as a static library and you link to it in your shared library." OFF)

vulkan/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ add_granite_internal_lib(granite-vulkan
2929
query_pool.cpp query_pool.hpp
3030
texture/texture_format.cpp texture/texture_format.hpp)
3131

32-
if (WIN32)
32+
if (WIN32 AND GRANITE_VULKAN_DXGI_INTEROP)
3333
target_sources(granite-vulkan PRIVATE wsi_dxgi.cpp wsi_dxgi.hpp)
3434
target_compile_definitions(granite-vulkan PUBLIC HAVE_WSI_DXGI_INTEROP)
3535
endif()

0 commit comments

Comments
 (0)