[client] renderers: only rebuild the font atlas if marked dirty

This commit is contained in:
Geoffrey McRae
2026-07-30 12:48:30 +10:00
parent 9657ac7aa2
commit f5dee45adc
6 changed files with 35 additions and 11 deletions

View File

@@ -33,6 +33,7 @@
(x)->deinitialize && \
(x)->onRestart && \
(x)->onResize && \
(x)->onFontUpdate && \
(x)->onMouseShape && \
(x)->onMouseEvent && \
(x)->renderStartup && \
@@ -185,6 +186,10 @@ typedef struct LG_RendererOps
const double scale, const LG_RendererRect destRect,
LG_RendererRotate rotate);
/* called when the Dear ImGui font atlas texture must be uploaded
* Context: renderThread */
bool (*onFontUpdate)(LG_Renderer * renderer);
/* called when the mouse shape has changed
* Context: cursorThread */
bool (*onMouseShape)(LG_Renderer * renderer, const LG_RendererCursor cursor,