瀏覽代碼

Fonts: GC Compact All exposed in Metrics->Memory Allocations includes compacting texture data.

ocornut 5 月之前
父節點
當前提交
074bf39e40
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      imgui.cpp

+ 1 - 0
imgui.cpp

@@ -4394,6 +4394,7 @@ void ImGui::GcCompactTransientMiscBuffers()
     g.MultiSelectTempDataStacked = 0;
     g.MultiSelectTempDataStacked = 0;
     g.MultiSelectTempData.clear_destruct();
     g.MultiSelectTempData.clear_destruct();
     TableGcCompactSettings();
     TableGcCompactSettings();
+    g.IO.Fonts->CompactCache();
 }
 }
 
 
 // Free up/compact internal window buffers, we can use this when a window becomes unused.
 // Free up/compact internal window buffers, we can use this when a window becomes unused.