Refactor: Merge the ChooseDevice function into CreateDevice

This commit is contained in:
Henrik Rydgård committed 2024-07-17 10:31:49 +02:00
1 parent cb9c230e4e
commit 9f1f75ddab
5 files changed
+34 -41

No files matched your search

+1 -2
View File
@@ -84,8 +84,7 @@ bool SDLVulkanGraphicsContext::Init(SDL_Window *&window, int x, int y, int w, in
g_Config.sVulkanDevice = vulkan_->GetPhysicalDeviceProperties(deviceNum).properties.deviceName;
}
vulkan_->ChooseDevice(deviceNum);
if (vulkan_->CreateDevice() != VK_SUCCESS) {
if (vulkan_->CreateDevice(deviceNum) != VK_SUCCESS) {
*error_message = vulkan_->InitError();
delete vulkan_;
vulkan_ = nullptr;