mirror of
https://github.com/skyline-emu/skyline.git
synced 2024-11-30 09:34:18 +01:00
Switch from VK_VERSION_*
to VK_API_VERSION_*
macros
Vulkan has officially deprecated `VK_VERSION_*` macros for versioning as it has introduced the variant into the version. It should however be `0` for the Vulkan APi and doesn't need to be printed.
This commit is contained in:
parent
0588a525b4
commit
51c4df24b5
@ -25,7 +25,7 @@ namespace skyline::gpu {
|
|||||||
if (Logger::configLevel >= Logger::LogLevel::Debug) {
|
if (Logger::configLevel >= Logger::LogLevel::Debug) {
|
||||||
std::string layers;
|
std::string layers;
|
||||||
for (const auto &instanceLayer : instanceLayers)
|
for (const auto &instanceLayer : instanceLayers)
|
||||||
layers += util::Format("\n* {} (Sv{}.{}.{}, Iv{}.{}.{}) - {}", instanceLayer.layerName, VK_VERSION_MAJOR(instanceLayer.specVersion), VK_VERSION_MINOR(instanceLayer.specVersion), VK_VERSION_PATCH(instanceLayer.specVersion), VK_VERSION_MAJOR(instanceLayer.implementationVersion), VK_VERSION_MINOR(instanceLayer.implementationVersion), VK_VERSION_PATCH(instanceLayer.implementationVersion), instanceLayer.description);
|
layers += util::Format("\n* {} (Sv{}.{}.{}, Iv{}.{}.{}) - {}", instanceLayer.layerName, VK_API_VERSION_MAJOR(instanceLayer.specVersion), VK_API_VERSION_MINOR(instanceLayer.specVersion), VK_API_VERSION_PATCH(instanceLayer.specVersion), VK_API_VERSION_MAJOR(instanceLayer.implementationVersion), VK_API_VERSION_MINOR(instanceLayer.implementationVersion), VK_API_VERSION_PATCH(instanceLayer.implementationVersion), instanceLayer.description);
|
||||||
Logger::Debug("Vulkan Layers:{}", layers);
|
Logger::Debug("Vulkan Layers:{}", layers);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -46,7 +46,7 @@ namespace skyline::gpu {
|
|||||||
if (Logger::configLevel >= Logger::LogLevel::Debug) {
|
if (Logger::configLevel >= Logger::LogLevel::Debug) {
|
||||||
std::string extensions;
|
std::string extensions;
|
||||||
for (const auto &instanceExtension : instanceExtensions)
|
for (const auto &instanceExtension : instanceExtensions)
|
||||||
extensions += util::Format("\n* {} (v{}.{}.{})", instanceExtension.extensionName, VK_VERSION_MAJOR(instanceExtension.specVersion), VK_VERSION_MINOR(instanceExtension.specVersion), VK_VERSION_PATCH(instanceExtension.specVersion));
|
extensions += util::Format("\n* {} (v{}.{}.{})", instanceExtension.extensionName, VK_API_VERSION_MAJOR(instanceExtension.specVersion), VK_API_VERSION_MINOR(instanceExtension.specVersion), VK_API_VERSION_PATCH(instanceExtension.specVersion));
|
||||||
Logger::Debug("Vulkan Instance Extensions:{}", extensions);
|
Logger::Debug("Vulkan Instance Extensions:{}", extensions);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -179,7 +179,7 @@ namespace skyline::gpu {
|
|||||||
if (Logger::configLevel >= Logger::LogLevel::Info) {
|
if (Logger::configLevel >= Logger::LogLevel::Info) {
|
||||||
std::string extensionString;
|
std::string extensionString;
|
||||||
for (const auto &extension : deviceExtensions)
|
for (const auto &extension : deviceExtensions)
|
||||||
extensionString += util::Format("\n* {} (v{}.{}.{})", extension.extensionName, VK_VERSION_MAJOR(extension.specVersion), VK_VERSION_MINOR(extension.specVersion), VK_VERSION_PATCH(extension.specVersion));
|
extensionString += util::Format("\n* {} (v{}.{}.{})", extension.extensionName, VK_API_VERSION_MAJOR(extension.specVersion), VK_API_VERSION_MINOR(extension.specVersion), VK_API_VERSION_PATCH(extension.specVersion));
|
||||||
|
|
||||||
std::string queueString;
|
std::string queueString;
|
||||||
u32 familyIndex{};
|
u32 familyIndex{};
|
||||||
@ -188,8 +188,8 @@ namespace skyline::gpu {
|
|||||||
|
|
||||||
Logger::Info("Vulkan Device:\nName: {}\nType: {}\nVulkan Version: {}.{}.{}\nDriver Version: {}.{}.{}\nQueues:{}\nExtensions:{}\nQuirks:{}",
|
Logger::Info("Vulkan Device:\nName: {}\nType: {}\nVulkan Version: {}.{}.{}\nDriver Version: {}.{}.{}\nQueues:{}\nExtensions:{}\nQuirks:{}",
|
||||||
properties.deviceName, vk::to_string(properties.deviceType),
|
properties.deviceName, vk::to_string(properties.deviceType),
|
||||||
VK_VERSION_MAJOR(properties.apiVersion), VK_VERSION_MINOR(properties.apiVersion), VK_VERSION_PATCH(properties.apiVersion),
|
VK_API_VERSION_MAJOR(properties.apiVersion), VK_API_VERSION_MINOR(properties.apiVersion), VK_API_VERSION_PATCH(properties.apiVersion),
|
||||||
VK_VERSION_MAJOR(properties.driverVersion), VK_VERSION_MINOR(properties.driverVersion), VK_VERSION_PATCH(properties.driverVersion),
|
VK_API_VERSION_MAJOR(properties.driverVersion), VK_API_VERSION_MINOR(properties.driverVersion), VK_API_VERSION_PATCH(properties.driverVersion),
|
||||||
queueString, extensionString, quirks.Summary());
|
queueString, extensionString, quirks.Summary());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -202,5 +202,15 @@ namespace skyline::gpu {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
GPU::GPU(const DeviceState &state) : vkInstance(CreateInstance(state, vkContext)), vkDebugReportCallback(CreateDebugReportCallback(vkInstance)), vkPhysicalDevice(CreatePhysicalDevice(vkInstance)), vkDevice(CreateDevice(vkPhysicalDevice, vkQueueFamilyIndex, quirks)), vkQueue(vkDevice, vkQueueFamilyIndex, 0), memory(*this), scheduler(*this), presentation(state, *this), texture(*this), shader(state, *this) {}
|
GPU::GPU(const DeviceState &state)
|
||||||
|
: vkInstance(CreateInstance(state, vkContext)),
|
||||||
|
vkDebugReportCallback(CreateDebugReportCallback(vkInstance)),
|
||||||
|
vkPhysicalDevice(CreatePhysicalDevice(vkInstance)),
|
||||||
|
vkDevice(CreateDevice(vkPhysicalDevice, vkQueueFamilyIndex, quirks)),
|
||||||
|
vkQueue(vkDevice, vkQueueFamilyIndex, 0),
|
||||||
|
memory(*this),
|
||||||
|
scheduler(*this),
|
||||||
|
presentation(state, *this),
|
||||||
|
texture(*this),
|
||||||
|
shader(state, *this) {}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user