Skip to content

Commit

Permalink
deps: sync imgui_impl_vulkan.cpp with upstream
Browse files Browse the repository at this point in the history
  • Loading branch information
scribam committed Feb 24, 2024
1 parent 142b06e commit cba5dec
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions core/deps/imgui/backends/imgui_impl_vulkan.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -502,11 +502,6 @@ void ImGui_ImplVulkan_RenderDrawData(ImDrawData* draw_data, VkCommandBuffer comm
// Create or resize the vertex/index buffers
size_t vertex_size = AlignBufferSize(draw_data->TotalVtxCount * sizeof(ImDrawVert), bd->BufferMemoryAlignment);
size_t index_size = AlignBufferSize(draw_data->TotalIdxCount * sizeof(ImDrawIdx), bd->BufferMemoryAlignment);
if (vertex_size != 0)
vertex_size = ((vertex_size - 1) / bd->BufferMemoryAlignment + 1) * bd->BufferMemoryAlignment;
if (index_size != 0)
index_size = ((index_size - 1) / bd->BufferMemoryAlignment + 1) * bd->BufferMemoryAlignment;

if (rb->VertexBuffer == VK_NULL_HANDLE || rb->VertexBufferSize < vertex_size)
CreateOrResizeBuffer(rb->VertexBuffer, rb->VertexBufferMemory, rb->VertexBufferSize, vertex_size, VK_BUFFER_USAGE_VERTEX_BUFFER_BIT);
if (rb->IndexBuffer == VK_NULL_HANDLE || rb->IndexBufferSize < index_size)
Expand Down

0 comments on commit cba5dec

Please sign in to comment.