Skip to content

Commit

Permalink
XMB: Color tuning (#17547)
Browse files Browse the repository at this point in the history
  • Loading branch information
sonninnos authored Feb 10, 2025
1 parent c1077a5 commit 87b3032
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 24 deletions.
2 changes: 1 addition & 1 deletion gfx/gfx_display.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
#include "../retroarch.h"
#include "../gfx/font_driver.h"

#define GFX_SHADOW_ALPHA 0.75f
#define GFX_SHADOW_ALPHA 1.00f

/* Number of pixels corner-to-corner on a 1080p
* display:
Expand Down
30 changes: 7 additions & 23 deletions menu/drivers/xmb.c
Original file line number Diff line number Diff line change
Expand Up @@ -779,10 +779,10 @@ static float *xmb_gradient_ident(unsigned xmb_color_theme)
0.05, 0.05, 0.05, 1.0,
};
static float gradient_light[16] = {
0.5, 0.5, 0.5, 1.0,
0.5, 0.5, 0.5, 1.0,
0.5, 0.5, 0.5, 1.0,
0.5, 0.5, 0.5, 1.0,
0.25, 0.25, 0.25, 1.0,
0.25, 0.25, 0.25, 1.0,
0.25, 0.25, 0.25, 1.0,
0.25, 0.25, 0.25, 1.0,
};

switch (xmb_color_theme)
Expand Down Expand Up @@ -7539,7 +7539,7 @@ static void xmb_layout_ps3(xmb_handle_t *xmb, int width)
xmb->items_active_alpha = 1.0;
xmb->items_passive_alpha = 0.75;

xmb->shadow_offset = 3.0 * scale_factor;
xmb->shadow_offset = 4.0 * scale_factor;
if (xmb->shadow_offset < 1.0)
xmb->shadow_offset = 1.0;
if (xmb->shadow_offset > 2.0)
Expand Down Expand Up @@ -7594,7 +7594,7 @@ static void xmb_layout_psp(xmb_handle_t *xmb, int width)
xmb->items_active_alpha = 1.0;
xmb->items_passive_alpha = 0.75;

xmb->shadow_offset = 3.0 * scale_factor;
xmb->shadow_offset = 4.0 * scale_factor;
if (xmb->shadow_offset < 1.0)
xmb->shadow_offset = 1.0;
if (xmb->shadow_offset > 2.0)
Expand Down Expand Up @@ -8372,23 +8372,7 @@ static bool xmb_context_reset_textures(
|| menu_xmb_theme == XMB_ICON_THEME_AUTOMATIC_INVERTED)
memcpy(xmb_item_color, xmb_coord_black, sizeof(xmb_item_color));
else
{
if ( menu_xmb_theme == XMB_ICON_THEME_MONOCHROME
|| menu_xmb_theme == XMB_ICON_THEME_AUTOMATIC)
{
for (i = 0; i < 16; i++)
{
if ((i == 3) || (i == 7) || (i == 11) || (i == 15))
{
xmb_item_color[i] = 1;
continue;
}
xmb_item_color[i] = 0.95;
}
}
else
memcpy(xmb_item_color, xmb_coord_white, sizeof(xmb_item_color));
}
memcpy(xmb_item_color, xmb_coord_white, sizeof(xmb_item_color));

return true;
}
Expand Down

0 comments on commit 87b3032

Please sign in to comment.