mirror of
https://github.com/Drezil/imgui.git
synced 2024-11-25 21:17:01 +00:00
Fix new Vulkan validation warnings
This commit is contained in:
parent
6384eee34f
commit
509df3e279
@ -236,10 +236,10 @@ void ImGui_ImplGlfwVulkan_RenderDrawLists(ImDrawData* draw_data)
|
||||
VkMappedMemoryRange range[2] = {};
|
||||
range[0].sType = VK_STRUCTURE_TYPE_MAPPED_MEMORY_RANGE;
|
||||
range[0].memory = g_VertexBufferMemory[g_FrameIndex];
|
||||
range[0].size = vertex_size;
|
||||
range[0].size = VK_WHOLE_SIZE;
|
||||
range[1].sType = VK_STRUCTURE_TYPE_MAPPED_MEMORY_RANGE;
|
||||
range[1].memory = g_IndexBufferMemory[g_FrameIndex];
|
||||
range[1].size = index_size;
|
||||
range[1].size = VK_WHOLE_SIZE;
|
||||
err = vkFlushMappedMemoryRanges(g_Device, 2, range);
|
||||
ImGui_ImplGlfwVulkan_VkResult(err);
|
||||
vkUnmapMemory(g_Device, g_VertexBufferMemory[g_FrameIndex]);
|
||||
@ -483,6 +483,7 @@ bool ImGui_ImplGlfwVulkan_CreateFontsTexture(VkCommandBuffer command_buffer)
|
||||
region.imageSubresource.layerCount = 1;
|
||||
region.imageExtent.width = width;
|
||||
region.imageExtent.height = height;
|
||||
region.imageExtent.depth = 1;
|
||||
vkCmdCopyBufferToImage(command_buffer, g_UploadBuffer, g_FontImage, VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, 1, ®ion);
|
||||
|
||||
VkImageMemoryBarrier use_barrier[1] = {};
|
||||
|
Loading…
Reference in New Issue
Block a user