Merge pull request #796 from asuessenbach/registry

Correct usage of VulkanRegistry_DIR
This commit is contained in:
Andreas Süßenbach 2020-10-21 16:27:11 +02:00 committed by GitHub
commit 7552d3a5ab
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -56,12 +56,12 @@ message("CMAKE_CXX_STANDARD = <${CMAKE_CXX_STANDARD}>")
if (NOT DEFINED VulkanRegistry_DIR)
if (DEFINED VULKAN_HPP_VULKAN_HEADERS_SRC_DIR)
set(VulkanRegistry_DIR ${VULKAN_HPP_VULKAN_HEADERS_SRC_DIR})
set(VulkanRegistry_DIR "${VULKAN_HPP_VULKAN_HEADERS_SRC_DIR/registry"})
else()
set(VulkanRegistry_DIR "${CMAKE_CURRENT_SOURCE_DIR}/Vulkan-Headers")
set(VulkanRegistry_DIR "${CMAKE_CURRENT_SOURCE_DIR}/Vulkan-Headers/registry")
endif()
endif()
file(TO_NATIVE_PATH ${VulkanRegistry_DIR}/registry/vk.xml vk_spec)
file(TO_NATIVE_PATH ${VulkanRegistry_DIR}/vk.xml vk_spec)
string(REPLACE "\\" "\\\\" vk_spec ${vk_spec})
add_definitions(-DVK_SPEC="${vk_spec}")

View File

@ -543,7 +543,7 @@ namespace VULKAN_HPP_NAMESPACE
return std::array<T, N>::operator[]( index );
}
VULKAN_HPP_CONSTEXPR T & operator[]( int index ) VULKAN_HPP_NOEXCEPT
T & operator[]( int index ) VULKAN_HPP_NOEXCEPT
{
return std::array<T, N>::operator[]( index );
}