From 75e0c5048ec85307434ddead12d40c192dad6b44 Mon Sep 17 00:00:00 2001 From: DanS Date: Tue, 13 Oct 2026 13:30:20 -0500 Subject: [PATCH] fix(theme): give the menu acrylic the card blur radius Every panel class samples one shared blur texture, so a menu asking for a different blur radius than cards could not actually get it. All it did was force a second full-screen blur pass each frame as the radius flipped between the card and menu values, and let whichever class drew last decide the radius for everything. - Setting the acrylic theme now copies the card blur radius onto the menu class, so menus and cards share one radius and the blur runs once per frame. The first-use default path goes through the same setter so it is covered too. Co-Authored-By: Claude Opus 4.8 --- src/ui/theme.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/ui/theme.cpp b/src/ui/theme.cpp index 2e1148e..8a7e5cd 100644 --- a/src/ui/theme.cpp +++ b/src/ui/theme.cpp @@ -181,8 +181,7 @@ AcrylicTheme GetLightAcrylicTheme() const AcrylicTheme& GetCurrentAcrylicTheme() { if (!s_acrylicThemeInitialized) { - s_currentAcrylicTheme = GetDragonXAcrylicTheme(); - s_acrylicThemeInitialized = true; + SetCurrentAcrylicTheme(GetDragonXAcrylicTheme()); } return s_currentAcrylicTheme; } @@ -190,6 +189,10 @@ const AcrylicTheme& GetCurrentAcrylicTheme() void SetCurrentAcrylicTheme(const AcrylicTheme& theme) { s_currentAcrylicTheme = theme; + // Every panel class samples ONE shared blur texture, so a per-class radius cannot be honoured + // anyway: it only makes applyBlur() re-blur twice per frame (card <-> menu) and lets the last + // radius drawn win for all cards. Menus use the card radius. + s_currentAcrylicTheme.menu.blurRadius = s_currentAcrylicTheme.card.blurRadius; s_acrylicThemeInitialized = true; }