mirror of
https://github.com/libretro/RetroArch.git
synced 2026-11-09 03:29:43 -10:00
GDI: honour xmb_shadows_enable
Drop shadows for XMB icons, text, and thumbnails were force-disabled in gdi_frame alongside menu_shader_pipeline. The latter is correct -- GDI has no programmable pipeline, so the animated XMB backgrounds (Ribbon / Snow / Bokeh / etc.) can't run. But shadow draws are just black-tinted textured quads and tinted glyphs, which the texture-modulated slow path in gdi_blit_texture_modulated and the tinted-glyph path in gdi_font_render_line handle correctly: pixels land as premultiplied black with the shadow alpha, AlphaBlend with AC_SRC_OVER + AC_SRC_ALPHA composites them as expected. Carryover from the legacy driver that predated those paths. gl1 has the same clobber for the same legacy reason; left alone here since its fixed-function tint behaviour hasn't been verified.
This commit is contained in:
1 parent
caeecd5463
commit
709d4622c9
1 file changed
+15
-5
+15
-5
@@ -2612,11 +2612,21 @@ static bool gdi_frame(void *data, const void *frame,
|
||||
unsigned surface_width;
|
||||
unsigned surface_height;
|
||||
|
||||
/* GDI does not implement these effects. XMB still calls into the
|
||||
* shader-pipeline draw path, so we force-disable the bits that
|
||||
* would route through it; this is preserved verbatim from the
|
||||
* legacy driver. */
|
||||
video_info->xmb_shadows_enable = false;
|
||||
/* GDI has no programmable shader pipeline, so the animated XMB
|
||||
* backgrounds (Ribbon / Snow / Bokeh / etc.) can't run — force
|
||||
* that off so XMB falls back to the static gradient.
|
||||
*
|
||||
* xmb_shadows_enable, on the other hand, is just "draw the icon
|
||||
* and text once at +offset with a black tint, then once more on
|
||||
* top". The texture-modulated slow path in
|
||||
* gdi_blit_texture_modulated and the tinted-glyph path in
|
||||
* gdi_font_render_line both handle that correctly: pixels land
|
||||
* as premultiplied black with the shadow alpha, AlphaBlend with
|
||||
* AC_SRC_OVER + AC_SRC_ALPHA composites them as expected. So
|
||||
* this flag is honoured rather than clobbered. (The legacy GDI
|
||||
* driver predated those paths and force-disabled both flags
|
||||
* together; gl1 still does the same thing for the same legacy
|
||||
* reason.) */
|
||||
video_info->menu_shader_pipeline = 0;
|
||||
|
||||
if (!frame || !frame_width || !frame_height)
|
||||
|
||||
Reference in new issue
Block a user