summaryrefslogtreecommitdiff
path: root/vulkan/libvulkan/driver.cpp
diff options
context:
space:
mode:
author Ian Elliott <ianelliott@google.com> 2021-07-20 17:40:24 -0600
committer Trevor David Black <vantablack@google.com> 2022-01-24 15:54:20 +0000
commitfa7af492359030e28391e1a13d7b9749057d3603 (patch)
tree6d3492f58ee74c4285aefdf3d7b39b63025c982e /vulkan/libvulkan/driver.cpp
parent9fed2ba5c83d734f4c977c1404b042f210c7063c (diff)
Change Vulkan API to 1.2
The commit changes the platform code to support Vulkan 1.2. Bug: 191881132 Test: build Change-Id: I6e71a84b85874a71031734004b8e44ee0ea7446f
Diffstat (limited to 'vulkan/libvulkan/driver.cpp')
-rw-r--r--vulkan/libvulkan/driver.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/vulkan/libvulkan/driver.cpp b/vulkan/libvulkan/driver.cpp
index cf774fd9b8..ffc7c94566 100644
--- a/vulkan/libvulkan/driver.cpp
+++ b/vulkan/libvulkan/driver.cpp
@@ -365,7 +365,7 @@ CreateInfoWrapper::CreateInfoWrapper(const VkInstanceCreateInfo& create_info,
const VkAllocationCallbacks& allocator)
: is_instance_(true),
allocator_(allocator),
- loader_api_version_(VK_API_VERSION_1_1),
+ loader_api_version_(VK_API_VERSION_1_2),
icd_api_version_(icd_api_version),
physical_dev_(VK_NULL_HANDLE),
instance_info_(create_info),
@@ -377,7 +377,7 @@ CreateInfoWrapper::CreateInfoWrapper(VkPhysicalDevice physical_dev,
const VkAllocationCallbacks& allocator)
: is_instance_(false),
allocator_(allocator),
- loader_api_version_(VK_API_VERSION_1_1),
+ loader_api_version_(VK_API_VERSION_1_2),
icd_api_version_(icd_api_version),
physical_dev_(physical_dev),
dev_info_(create_info),
@@ -519,6 +519,10 @@ VkResult CreateInfoWrapper::SanitizeExtensions() {
is_instance_ ? loader_api_version_
: std::min(icd_api_version_, loader_api_version_);
switch (api_version) {
+ case VK_API_VERSION_1_2:
+ hook_extensions_.set(ProcHook::EXTENSION_CORE_1_2);
+ hal_extensions_.set(ProcHook::EXTENSION_CORE_1_2);
+ [[clang::fallthrough]];
case VK_API_VERSION_1_1:
hook_extensions_.set(ProcHook::EXTENSION_CORE_1_1);
hal_extensions_.set(ProcHook::EXTENSION_CORE_1_1);