mirror of
https://github.com/RaySollium99/picodrive.git
synced 2025-09-05 15:27:46 -04:00
ui, fix for SDL emulation display if resolution != 320x240
This commit is contained in:
parent
8094d3362f
commit
832faed320
7 changed files with 30 additions and 15 deletions
|
@ -211,17 +211,23 @@ void plat_video_menu_leave(void)
|
|||
|
||||
void plat_video_loop_prepare(void)
|
||||
{
|
||||
plat_sdl_change_video_mode(g_screen_width, g_screen_height, 0);
|
||||
|
||||
if (plat_sdl_overlay != NULL || plat_sdl_gl_active) {
|
||||
g_screen_ptr = shadow_fb;
|
||||
g_screen_width = 320;
|
||||
g_screen_height = 240;
|
||||
g_screen_ppitch = g_screen_width;
|
||||
}
|
||||
else {
|
||||
if (SDL_MUSTLOCK(plat_sdl_screen))
|
||||
SDL_LockSurface(plat_sdl_screen);
|
||||
g_screen_ptr = plat_sdl_screen->pixels;
|
||||
g_screen_width = g_menuscreen_w;
|
||||
g_screen_height = g_menuscreen_h;
|
||||
g_screen_ppitch = g_menuscreen_pp;
|
||||
}
|
||||
plat_video_set_buffer(g_screen_ptr);
|
||||
|
||||
plat_sdl_change_video_mode(g_screen_width, g_screen_height, 0);
|
||||
}
|
||||
|
||||
void plat_early_init(void)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue