mirror of
https://github.com/charles-lunarg/vk-bootstrap.git
synced 2024-11-22 15:24:34 +00:00
Fixed bugs in check_device_extension_support
This commit is contained in:
parent
bfcc4c6bfa
commit
dde974d912
@ -288,7 +288,8 @@ detail::Expected<Instance, detail::Error<InstanceError>> InstanceBuilder::build
|
||||
|
||||
uint32_t api_version = VK_MAKE_VERSION (1, 0, 0);
|
||||
|
||||
if (info.required_api_version > VK_MAKE_VERSION (1, 0, 0) || info.desired_api_version > VK_MAKE_VERSION (1, 0, 0)) {
|
||||
if (info.required_api_version > VK_MAKE_VERSION (1, 0, 0) ||
|
||||
info.desired_api_version > VK_MAKE_VERSION (1, 0, 0)) {
|
||||
PFN_vkEnumerateInstanceVersion pfn_vkEnumerateInstanceVersion;
|
||||
detail::get_inst_proc_addr (
|
||||
pfn_vkEnumerateInstanceVersion, "vkEnumerateInstanceVersion", nullptr, vkGetInstanceProcAddr);
|
||||
@ -543,10 +544,12 @@ std::vector<const char*> check_device_extension_support (
|
||||
std::vector<const char*> extensions_to_enable;
|
||||
for (const auto& extension : available_extensions.value ()) {
|
||||
for (auto& req_ext : desired_extensions) {
|
||||
if (req_ext == extension.extensionName) extensions_to_enable.push_back (req_ext);
|
||||
if (strcmp (req_ext, extension.extensionName) == 0) {
|
||||
extensions_to_enable.push_back (req_ext);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return extensions_to_enable;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user