summaryrefslogtreecommitdiffstats
path: root/src/video_core
diff options
context:
space:
mode:
authorLioncash <mathew1800@gmail.com>2020-07-17 00:26:30 +0200
committerLioncash <mathew1800@gmail.com>2020-07-17 00:26:30 +0200
commit7d5f93832cdec42d11057f20550a47325f47d3d3 (patch)
tree122da2558437e6be7389e88e23f6320e8a33a0c2 /src/video_core
parentvk_image: Make use of designated initializers where applicable (diff)
downloadyuzu-7d5f93832cdec42d11057f20550a47325f47d3d3.tar
yuzu-7d5f93832cdec42d11057f20550a47325f47d3d3.tar.gz
yuzu-7d5f93832cdec42d11057f20550a47325f47d3d3.tar.bz2
yuzu-7d5f93832cdec42d11057f20550a47325f47d3d3.tar.lz
yuzu-7d5f93832cdec42d11057f20550a47325f47d3d3.tar.xz
yuzu-7d5f93832cdec42d11057f20550a47325f47d3d3.tar.zst
yuzu-7d5f93832cdec42d11057f20550a47325f47d3d3.zip
Diffstat (limited to 'src/video_core')
-rw-r--r--src/video_core/renderer_vulkan/vk_memory_manager.cpp13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/video_core/renderer_vulkan/vk_memory_manager.cpp b/src/video_core/renderer_vulkan/vk_memory_manager.cpp
index b4c650a63..24c8960ac 100644
--- a/src/video_core/renderer_vulkan/vk_memory_manager.cpp
+++ b/src/video_core/renderer_vulkan/vk_memory_manager.cpp
@@ -178,13 +178,12 @@ bool VKMemoryManager::AllocMemory(VkMemoryPropertyFlags wanted_properties, u32 t
}();
// Try to allocate found type.
- VkMemoryAllocateInfo memory_ai;
- memory_ai.sType = VK_STRUCTURE_TYPE_MEMORY_ALLOCATE_INFO;
- memory_ai.pNext = nullptr;
- memory_ai.allocationSize = size;
- memory_ai.memoryTypeIndex = type;
-
- vk::DeviceMemory memory = device.GetLogical().TryAllocateMemory(memory_ai);
+ vk::DeviceMemory memory = device.GetLogical().TryAllocateMemory({
+ .sType = VK_STRUCTURE_TYPE_MEMORY_ALLOCATE_INFO,
+ .pNext = nullptr,
+ .allocationSize = size,
+ .memoryTypeIndex = type,
+ });
if (!memory) {
LOG_CRITICAL(Render_Vulkan, "Device allocation failed!");
return false;