mirror of
https://github.com/charles-lunarg/vk-bootstrap.git
synced 2024-11-10 02:41:47 +00:00
Fix removal of unsuitable devices when using only_fully_suitable selection
This commit is contained in:
parent
e78a1822c1
commit
97734970f0
@ -1235,8 +1235,8 @@ detail::Result<std::vector<PhysicalDevice>> PhysicalDeviceSelector::select_impl(
|
||||
});
|
||||
|
||||
// Remove the partially suitable elements if they aren't desired
|
||||
if (selection == DeviceSelectionMode::only_fully_suitable) {
|
||||
physical_devices.erase(partition_index, physical_devices.end() - 1);
|
||||
if (selection == DeviceSelectionMode::only_fully_suitable && partition_index != physical_devices.end()) {
|
||||
physical_devices.erase(partition_index, physical_devices.end());
|
||||
}
|
||||
|
||||
// Make the physical device ready to be used to create a Device from it
|
||||
|
Loading…
Reference in New Issue
Block a user