gpt4 book ai didi

vulkan - 遵循 vulkan 教程时如何修复 mac m1 上的 VK_KHR_portability_subset 错误

转载 作者:行者123 更新时间:2023-12-05 01:58:57 26 4
gpt4 key购买 nike

您好,我在编译时遇到错误。显然我缺少一个扩展:

validation layer: Validation Error: [ VUID-VkDeviceCreateInfo-pProperties-04451 ] Object 0: handle = 0x1055040c0, type = VK_OBJECT_TYPE_PHYSICAL_DEVICE; | MessageID = 0x3a3b6ca0 | vkCreateDevice: VK_KHR_portability_subset must be enabled because physical device VkPhysicalDevice 0x1055040c0[] supports it The Vulkan spec states: If the [VK_KHR_portability_subset] extension is included in pProperties of vkEnumerateDeviceExtensionProperties, ppEnabledExtensions must include "VK_KHR_portability_subset". (https://vulkan.lunarg.com/doc/view/1.2.176.1/mac/1.2-extensions/vkspec.html#VUID-VkDeviceCreateInfo-pProperties-04451)

我天真地添加到 deviceExtension 向量“VK_KHR_portability_subset”,然后得到第二个错误,似乎与前一个类似。

validation layer: Validation Error: [ VUID-vkCreateDevice-ppEnabledExtensionNames-01387 ] Object 0: VK_NULL_HANDLE, type = VK_OBJECT_TYPE_INSTANCE; | MessageID = 0x12537a2c | Missing extension required by the device extension VK_KHR_portability_subset: VK_KHR_get_physical_device_properties2. The Vulkan spec states: All required extensions for each extension in the VkDeviceCreateInfo::ppEnabledExtensionNames list must also be present in that list (https://vulkan.lunarg.com/doc/view/1.2.176.1/mac/1.2-extensions/vkspec.html#VUID-vkCreateDevice-ppEnabledExtensionNames-01387)

我添加到 deviceExtension 向量“VK_KHR_get_physical_device_properties2”然后得到第三个错误:

libc++abi: terminating with uncaught exception of type std::runtime_error: failed to find a suitable GPU!

问题是之前他认识到我使用的是 m1 芯片,但现在设备上没有显示任何信息:(

最佳答案

I added to the deviceExtension vector "VK_KHR_get_physical_device_properties2"

VK_KHR_get_physical_device_properties2 是一个实例扩展,因此属于 vkCreateInstance(不是 设备)。

据报道,这解决了您的问题。

关于vulkan - 遵循 vulkan 教程时如何修复 mac m1 上的 VK_KHR_portability_subset 错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/68127785/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com