diff --git a/src/backend.h b/src/backend.h index 37e93345b..f19456a75 100644 --- a/src/backend.h +++ b/src/backend.h @@ -2,8 +2,8 @@ #include "color_helpers.h" #include "gamescope_shared.h" +#include "vulkan_include.h" -#include "vulkan/vulkan_core.h" #include #include #include diff --git a/src/rendervulkan.cpp b/src/rendervulkan.cpp index 7cb3c1df3..d476d443b 100644 --- a/src/rendervulkan.cpp +++ b/src/rendervulkan.cpp @@ -10,7 +10,7 @@ #include #include #include -#include +#include "vulkan_include.h" #if defined(__linux__) #include @@ -2315,7 +2315,7 @@ bool CVulkanTexture::BInit( uint32_t width, uint32_t height, uint32_t depth, uin createInfo.format = VK_FORMAT_R8_UNORM; createInfo.subresourceRange.aspectMask = VK_IMAGE_ASPECT_PLANE_0_BIT; - res = vkCreateImageView(g_device.device(), &createInfo, nullptr, &m_lumaView); + res = g_device.vk.CreateImageView(g_device.device(), &createInfo, nullptr, &m_lumaView); if ( res != VK_SUCCESS ) { vk_errorf( res, "vkCreateImageView failed" ); return false; @@ -2324,7 +2324,7 @@ bool CVulkanTexture::BInit( uint32_t width, uint32_t height, uint32_t depth, uin createInfo.pNext = NULL; createInfo.format = VK_FORMAT_R8G8_UNORM; createInfo.subresourceRange.aspectMask = VK_IMAGE_ASPECT_PLANE_1_BIT; - res = vkCreateImageView(g_device.device(), &createInfo, nullptr, &m_chromaView); + res = g_device.vk.CreateImageView(g_device.device(), &createInfo, nullptr, &m_chromaView); if ( res != VK_SUCCESS ) { vk_errorf( res, "vkCreateImageView failed" ); return false; diff --git a/src/vulkan_include.h b/src/vulkan_include.h new file mode 100644 index 000000000..1f78e5232 --- /dev/null +++ b/src/vulkan_include.h @@ -0,0 +1,4 @@ +#pragma once + +#define VK_NO_PROTOTYPES +#include diff --git a/src/wlserver.hpp b/src/wlserver.hpp index c148847fb..f0b8e1e1c 100644 --- a/src/wlserver.hpp +++ b/src/wlserver.hpp @@ -11,7 +11,8 @@ #include #include #include -#include + +#include "vulkan_include.h" #include "steamcompmgr_shared.hpp"