[wpigui] Reload fonts to scale rather than preloading (#4712)

This commit is contained in:
Peter Johnson
2022-11-26 22:30:38 -08:00
committed by GitHub
parent e43e2fbc84
commit 1da84b2255
6 changed files with 76 additions and 40 deletions

View File

@@ -76,6 +76,11 @@ bool gui::PlatformInitRenderer() {
}
void gui::PlatformRenderFrame() {
if (gContext->reloadFonts) {
ImGui_ImplOpenGL3_DestroyFontsTexture();
ImGui_ImplOpenGL3_CreateFontsTexture();
gContext->reloadFonts = false;
}
ImGui_ImplOpenGL3_NewFrame();
CommonRenderFrame();