From 18fe910957b2edb7e89eefc6f5c984b791d85341 Mon Sep 17 00:00:00 2001 From: ReinUsesLisp Date: Tue, 12 Feb 2019 18:01:40 -0300 Subject: renderer_vulkan: Add declarations file This file is intended to be included instead of vulkan/vulkan.hpp. It includes declarations of unique handlers using a dynamic dispatcher instead of a static one (which would require linking to a Vulkan library). --- src/video_core/CMakeLists.txt | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/video_core/CMakeLists.txt') diff --git a/src/video_core/CMakeLists.txt b/src/video_core/CMakeLists.txt index 33e507e69..a12680d35 100644 --- a/src/video_core/CMakeLists.txt +++ b/src/video_core/CMakeLists.txt @@ -101,6 +101,13 @@ add_library(video_core STATIC video_core.h ) +if (ENABLE_VULKAN) + target_sources(video_core PRIVATE renderer_vulkan/declarations.h) + + target_include_directories(video_core PRIVATE ../../externals/Vulkan-Headers/include) + target_compile_definitions(video_core PRIVATE HAS_VULKAN) +endif() + create_target_directory_groups(video_core) target_link_libraries(video_core PUBLIC common core) -- cgit v1.2.3 From 8beca060d1585f530eaa36972edf7bc92f42bd7e Mon Sep 17 00:00:00 2001 From: ReinUsesLisp Date: Tue, 12 Feb 2019 18:28:05 -0300 Subject: vk_device: Abstract device handling into a class VKDevice contains all the data required to manage and initialize a physical device. Its intention is to be passed across Vulkan objects to query device-specific data (for example the logical device and the dispatch loader). --- src/video_core/CMakeLists.txt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/video_core/CMakeLists.txt') diff --git a/src/video_core/CMakeLists.txt b/src/video_core/CMakeLists.txt index a12680d35..a0cb6ba5f 100644 --- a/src/video_core/CMakeLists.txt +++ b/src/video_core/CMakeLists.txt @@ -102,7 +102,10 @@ add_library(video_core STATIC ) if (ENABLE_VULKAN) - target_sources(video_core PRIVATE renderer_vulkan/declarations.h) + target_sources(video_core PRIVATE + renderer_vulkan/declarations.h + renderer_vulkan/vk_device.cpp + renderer_vulkan/vk_device.h) target_include_directories(video_core PRIVATE ../../externals/Vulkan-Headers/include) target_compile_definitions(video_core PRIVATE HAS_VULKAN) -- cgit v1.2.3