mirror of
https://github.com/libretro/RetroArch
synced 2025-04-15 23:42:30 +00:00
Add to video_frame_info
This commit is contained in:
parent
c678d97270
commit
2322e77795
@ -337,13 +337,11 @@ void gl_set_viewport(void *data, video_frame_info_t *video_info,
|
|||||||
#if defined(HAVE_MENU)
|
#if defined(HAVE_MENU)
|
||||||
if (video_info->aspect_ratio_idx == ASPECT_RATIO_CUSTOM)
|
if (video_info->aspect_ratio_idx == ASPECT_RATIO_CUSTOM)
|
||||||
{
|
{
|
||||||
const struct video_viewport *custom = video_viewport_get_custom();
|
|
||||||
|
|
||||||
/* GL has bottom-left origin viewport. */
|
/* GL has bottom-left origin viewport. */
|
||||||
x = custom->x;
|
x = video_info->custom_vp_x;
|
||||||
y = height - custom->y - custom->height;
|
y = height - video_info->custom_vp_y - video_info->custom_vp_height;
|
||||||
viewport_width = custom->width;
|
viewport_width = video_info->custom_vp_width;
|
||||||
viewport_height = custom->height;
|
viewport_height = video_info->custom_vp_height;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
|
@ -2255,6 +2255,12 @@ void video_driver_build_info(video_frame_info_t *video_info)
|
|||||||
video_info->font_msg_color_r = settings->floats.video_msg_color_r;
|
video_info->font_msg_color_r = settings->floats.video_msg_color_r;
|
||||||
video_info->font_msg_color_g = settings->floats.video_msg_color_g;
|
video_info->font_msg_color_g = settings->floats.video_msg_color_g;
|
||||||
video_info->font_msg_color_b = settings->floats.video_msg_color_b;
|
video_info->font_msg_color_b = settings->floats.video_msg_color_b;
|
||||||
|
video_info->custom_vp_x = video_viewport_custom.x;
|
||||||
|
video_info->custom_vp_y = video_viewport_custom.y;
|
||||||
|
video_info->custom_vp_width = video_viewport_custom.width;
|
||||||
|
video_info->custom_vp_height = video_viewport_custom.height;
|
||||||
|
video_info->custom_vp_full_width = video_viewport_custom.full_width;
|
||||||
|
video_info->custom_vp_full_height = video_viewport_custom.full_height;
|
||||||
|
|
||||||
video_info->fps_text[0] = '\0';
|
video_info->fps_text[0] = '\0';
|
||||||
|
|
||||||
|
@ -159,6 +159,13 @@ typedef struct video_frame_info
|
|||||||
bool is_perfcnt_enable;
|
bool is_perfcnt_enable;
|
||||||
|
|
||||||
bool menu_is_alive;
|
bool menu_is_alive;
|
||||||
|
|
||||||
|
int custom_vp_x;
|
||||||
|
int custom_vp_y;
|
||||||
|
unsigned custom_vp_width;
|
||||||
|
unsigned custom_vp_height;
|
||||||
|
unsigned custom_vp_full_width;
|
||||||
|
unsigned custom_vp_full_height;
|
||||||
} video_frame_info_t;
|
} video_frame_info_t;
|
||||||
|
|
||||||
/* Optionally implemented interface to poke more
|
/* Optionally implemented interface to poke more
|
||||||
|
Loading…
x
Reference in New Issue
Block a user