mirror of
https://github.com/Drezil/imgui.git
synced 2024-11-15 09:27:00 +00:00
parent
ce7b04e8b9
commit
7a8eb5bdc9
@ -222,7 +222,7 @@ void ImDrawList::UpdateTextureID()
|
|||||||
|
|
||||||
// Try to merge with previous command if it matches, else use current command
|
// Try to merge with previous command if it matches, else use current command
|
||||||
ImDrawCmd* prev_cmd = CmdBuffer.Size > 1 ? curr_cmd - 1 : NULL;
|
ImDrawCmd* prev_cmd = CmdBuffer.Size > 1 ? curr_cmd - 1 : NULL;
|
||||||
if (prev_cmd && prev_cmd->TextureId == curr_texture_id && memcmp(&prev_cmd->ClipRect, &GetCurrentClipRect(), sizeof(ImVec4)) == 0 && prev_cmd->UserCallback == NULL)
|
if (curr_cmd->ElemCount == 0 && prev_cmd && prev_cmd->TextureId == curr_texture_id && memcmp(&prev_cmd->ClipRect, &GetCurrentClipRect(), sizeof(ImVec4)) == 0 && prev_cmd->UserCallback == NULL)
|
||||||
CmdBuffer.pop_back();
|
CmdBuffer.pop_back();
|
||||||
else
|
else
|
||||||
curr_cmd->TextureId = curr_texture_id;
|
curr_cmd->TextureId = curr_texture_id;
|
||||||
|
Loading…
Reference in New Issue
Block a user