diff --git a/src/dxvk/dxvk_device_filter.cpp b/src/dxvk/dxvk_device_filter.cpp index 62e617a4b..29f40de70 100644 --- a/src/dxvk/dxvk_device_filter.cpp +++ b/src/dxvk/dxvk_device_filter.cpp @@ -15,15 +15,12 @@ namespace dxvk { } - bool DxvkDeviceFilter::testAdapter( - const Rc& adapter) const { - const auto& deviceProps = adapter->deviceProperties(); - + bool DxvkDeviceFilter::testAdapter(const VkPhysicalDeviceProperties& properties) const { if (m_flags.test(DxvkDeviceFilterFlag::MatchDeviceName)) { - if (std::string (deviceProps.deviceName).find(m_matchDeviceName) == std::string::npos) + if (std::string(properties.deviceName).find(m_matchDeviceName) == std::string::npos) return false; } - + return true; } diff --git a/src/dxvk/dxvk_device_filter.h b/src/dxvk/dxvk_device_filter.h index b22da7e8a..a0cb9d04e 100644 --- a/src/dxvk/dxvk_device_filter.h +++ b/src/dxvk/dxvk_device_filter.h @@ -36,11 +36,11 @@ namespace dxvk { /** * \brief Tests an adapter * - * \param [in] adapter Adapter handle + * \param [in] properties Adapter properties * \returns \c true if the test passes */ bool testAdapter( - const Rc& adapter) const; + const VkPhysicalDeviceProperties& properties) const; private: diff --git a/src/dxvk/dxvk_instance.cpp b/src/dxvk/dxvk_instance.cpp index e9f706675..91d361d81 100644 --- a/src/dxvk/dxvk_instance.cpp +++ b/src/dxvk/dxvk_instance.cpp @@ -154,10 +154,13 @@ namespace dxvk { std::vector> result; for (uint32_t i = 0; i < numAdapters; i++) { - Rc adapter = new DxvkAdapter(m_vki, adapters[i]); - - if (filter.testAdapter(adapter)) - result.push_back(adapter); + VkPhysicalDeviceProperties deviceProperties; + m_vki->vkGetPhysicalDeviceProperties(adapters[i], &deviceProperties); + + if (deviceProperties.apiVersion < VK_MAKE_VERSION(1, 1, 0)) + Logger::warn(str::format("Skipping Vulkan 1.0 adapter: ", deviceProperties.deviceName)); + else if (filter.testAdapter(deviceProperties)) + result.push_back(new DxvkAdapter(m_vki, adapters[i])); } std::sort(result.begin(), result.end(),