mirror of
https://github.com/CTCaer/RetroArch.git
synced 2024-12-22 10:49:02 +00:00
(menu_display) Cleanups
This commit is contained in:
parent
19e86256a7
commit
033cecf08c
@ -834,12 +834,19 @@ static void mui_frame(void *data)
|
||||
draw.handle_alpha = 0.75f;
|
||||
draw.force_transparency = false;
|
||||
draw.color = &white_transp_bg[0];
|
||||
draw.color2 = &white_bg[0];
|
||||
draw.vertex = NULL;
|
||||
draw.tex_coord = NULL;
|
||||
draw.vertex_count = 4;
|
||||
draw.prim_type = MENU_DISPLAY_PRIM_TRIANGLESTRIP;
|
||||
|
||||
if (
|
||||
(settings->menu.pause_libretro
|
||||
|| !rarch_ctl(RARCH_CTL_IS_INITED, NULL)
|
||||
|| rarch_ctl(RARCH_CTL_IS_DUMMY_CORE, NULL)
|
||||
)
|
||||
&& !draw.force_transparency && draw.texture)
|
||||
draw.color = &white_bg[0];
|
||||
|
||||
menu_display_ctl(MENU_DISPLAY_CTL_DRAW_BG, &draw);
|
||||
}
|
||||
else
|
||||
@ -868,12 +875,19 @@ static void mui_frame(void *data)
|
||||
draw.handle_alpha = 0.75f;
|
||||
draw.force_transparency = true;
|
||||
draw.color = &white_transp_bg[0];
|
||||
draw.color2 = &white_bg[0];
|
||||
draw.vertex = NULL;
|
||||
draw.tex_coord = NULL;
|
||||
draw.vertex_count = 4;
|
||||
draw.prim_type = MENU_DISPLAY_PRIM_TRIANGLESTRIP;
|
||||
|
||||
if (
|
||||
(settings->menu.pause_libretro
|
||||
|| !rarch_ctl(RARCH_CTL_IS_INITED, NULL)
|
||||
|| rarch_ctl(RARCH_CTL_IS_DUMMY_CORE, NULL)
|
||||
)
|
||||
&& !draw.force_transparency && draw.texture)
|
||||
draw.color = &white_bg[0];
|
||||
|
||||
menu_display_ctl(MENU_DISPLAY_CTL_DRAW_BG, &draw);
|
||||
|
||||
/* Restore opacity of transposed white background */
|
||||
|
@ -1978,12 +1978,19 @@ static void xmb_frame(void *data)
|
||||
draw.handle_alpha = xmb->alpha;
|
||||
draw.force_transparency = false;
|
||||
draw.color = &coord_color[0];
|
||||
draw.color2 = &coord_color2[0];
|
||||
draw.vertex = NULL;
|
||||
draw.tex_coord = NULL;
|
||||
draw.vertex_count = 4;
|
||||
draw.prim_type = MENU_DISPLAY_PRIM_TRIANGLESTRIP;
|
||||
|
||||
if (
|
||||
(settings->menu.pause_libretro
|
||||
|| !rarch_ctl(RARCH_CTL_IS_INITED, NULL)
|
||||
|| rarch_ctl(RARCH_CTL_IS_DUMMY_CORE, NULL)
|
||||
)
|
||||
&& !draw.force_transparency && draw.texture)
|
||||
draw.color = &coord_color2[0];
|
||||
|
||||
xmb_draw_bg(&draw);
|
||||
|
||||
xmb_draw_text(xmb,
|
||||
@ -2110,12 +2117,19 @@ static void xmb_frame(void *data)
|
||||
draw.handle_alpha = xmb->alpha;
|
||||
draw.force_transparency = true;
|
||||
draw.color = &coord_color[0];
|
||||
draw.color2 = &coord_color2[0];
|
||||
draw.vertex = NULL;
|
||||
draw.tex_coord = NULL;
|
||||
draw.vertex_count = 4;
|
||||
draw.prim_type = MENU_DISPLAY_PRIM_TRIANGLESTRIP;
|
||||
|
||||
if (
|
||||
(settings->menu.pause_libretro
|
||||
|| !rarch_ctl(RARCH_CTL_IS_INITED, NULL)
|
||||
|| rarch_ctl(RARCH_CTL_IS_DUMMY_CORE, NULL)
|
||||
)
|
||||
&& !draw.force_transparency && draw.texture)
|
||||
draw.color = &coord_color2[0];
|
||||
|
||||
xmb_draw_bg(&draw);
|
||||
|
||||
xmb_render_messagebox_internal(xmb, msg);
|
||||
|
@ -43,6 +43,7 @@
|
||||
#include "../menu_display.h"
|
||||
#include "../menu_navigation.h"
|
||||
#include "../menu_hash.h"
|
||||
#include "../../retroarch.h"
|
||||
|
||||
#include "../../gfx/font_driver.h"
|
||||
|
||||
@ -1102,12 +1103,19 @@ static void zarch_frame(void *data)
|
||||
draw.handle_alpha = 0.75f;
|
||||
draw.force_transparency = false;
|
||||
draw.color = &coord_color[0];
|
||||
draw.color2 = &coord_color2[0];
|
||||
draw.vertex = NULL;
|
||||
draw.tex_coord = coord_draw.ptr;
|
||||
draw.vertex_count = 4;
|
||||
draw.prim_type = MENU_DISPLAY_PRIM_TRIANGLESTRIP;
|
||||
|
||||
if (
|
||||
(settings->menu.pause_libretro
|
||||
|| !rarch_ctl(RARCH_CTL_IS_INITED, NULL)
|
||||
|| rarch_ctl(RARCH_CTL_IS_DUMMY_CORE, NULL)
|
||||
)
|
||||
&& !draw.force_transparency && draw.texture)
|
||||
draw.color = &coord_color2[0];
|
||||
|
||||
menu_display_ctl(MENU_DISPLAY_CTL_DRAW_BG, &draw);
|
||||
|
||||
zui->rendering = false;
|
||||
|
@ -192,14 +192,6 @@ static void menu_display_d3d_draw_bg(void *data)
|
||||
|
||||
menu_display_ctl(MENU_DISPLAY_CTL_SET_VIEWPORT, NULL);
|
||||
|
||||
if (
|
||||
( settings->menu.pause_libretro
|
||||
|| !rarch_ctl(RARCH_CTL_IS_INITED, NULL)
|
||||
|| rarch_ctl(RARCH_CTL_IS_DUMMY_CORE, NULL)
|
||||
)
|
||||
&& !draw->force_transparency && draw->texture)
|
||||
coords.color = (const float*)draw->color2;
|
||||
|
||||
draw->x = 0;
|
||||
draw->y = 0;
|
||||
draw->matrix_data = (math_matrix_4x4*)
|
||||
|
@ -166,14 +166,6 @@ static void menu_display_gl_draw_bg(void *data)
|
||||
|
||||
menu_display_ctl(MENU_DISPLAY_CTL_SET_VIEWPORT, NULL);
|
||||
|
||||
if (
|
||||
(settings->menu.pause_libretro
|
||||
|| !rarch_ctl(RARCH_CTL_IS_INITED, NULL)
|
||||
|| rarch_ctl(RARCH_CTL_IS_DUMMY_CORE, NULL)
|
||||
)
|
||||
&& !draw->force_transparency && draw->texture)
|
||||
coords.color = (const float*)draw->color2;
|
||||
|
||||
draw->x = 0;
|
||||
draw->y = 0;
|
||||
draw->coords = &coords;
|
||||
|
@ -161,14 +161,6 @@ static void menu_display_vk_draw_bg(void *data)
|
||||
|
||||
menu_display_ctl(MENU_DISPLAY_CTL_SET_VIEWPORT, NULL);
|
||||
|
||||
if (
|
||||
(settings->menu.pause_libretro
|
||||
|| !rarch_ctl(RARCH_CTL_IS_INITED, NULL)
|
||||
|| rarch_ctl(RARCH_CTL_IS_DUMMY_CORE, NULL)
|
||||
)
|
||||
&& !draw->force_transparency && draw->texture)
|
||||
coords.color = (const float*)draw->color2;
|
||||
|
||||
draw->x = 0;
|
||||
draw->y = 0;
|
||||
draw->coords = &coords;
|
||||
|
@ -116,7 +116,6 @@ typedef struct menu_display_ctx_draw
|
||||
float handle_alpha;
|
||||
bool force_transparency;
|
||||
float *color;
|
||||
float *color2;
|
||||
const float *vertex;
|
||||
const float *tex_coord;
|
||||
size_t vertex_count;
|
||||
|
Loading…
Reference in New Issue
Block a user