mirror of
https://github.com/libretro/RetroArch
synced 2025-03-17 10:21:26 +00:00
menu display: use video_info for scissoring rect clipping
This commit is contained in:
parent
cdc165f340
commit
7c17cd9213
@ -521,20 +521,20 @@ void menu_display_scissor_begin(video_frame_info_t *video_info, int x, int y, un
|
||||
width += x;
|
||||
x = 0;
|
||||
}
|
||||
if (y >= (int)menu_display_framebuf_height)
|
||||
if (y >= (int)video_info->height)
|
||||
{
|
||||
height = 0;
|
||||
y = 0;
|
||||
}
|
||||
if (x >= (int)menu_display_framebuf_width)
|
||||
if (x >= (int)video_info->width)
|
||||
{
|
||||
width = 0;
|
||||
x = 0;
|
||||
}
|
||||
if ((y + height) > menu_display_framebuf_height)
|
||||
height = menu_display_framebuf_height - y;
|
||||
if ((x + width) > menu_display_framebuf_width)
|
||||
width = menu_display_framebuf_width - x;
|
||||
if ((y + height) > video_info->height)
|
||||
height = video_info->height - y;
|
||||
if ((x + width) > video_info->width)
|
||||
width = video_info->width - x;
|
||||
|
||||
menu_disp->scissor_begin(video_info, x, y, width, height);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user