mirror of
https://github.com/RaySollium99/picodrive.git
synced 2025-09-05 07:17:45 -04:00
platform sdl, add config file option for fullscreen
This commit is contained in:
parent
bd9cbae411
commit
74bd70403b
5 changed files with 7 additions and 6 deletions
|
@ -84,12 +84,12 @@ int main(int argc, char *argv[])
|
|||
//in_probe();
|
||||
|
||||
plat_target_init();
|
||||
plat_init();
|
||||
menu_init();
|
||||
|
||||
emu_prep_defconfig(); // depends on input
|
||||
emu_read_config(NULL, 0);
|
||||
|
||||
plat_init();
|
||||
menu_init();
|
||||
emu_init();
|
||||
|
||||
engineState = PGS_Menu;
|
||||
|
|
|
@ -1316,6 +1316,7 @@ static menu_entry e_menu_hidden[] =
|
|||
{
|
||||
mee_onoff("Accurate sprites", MA_OPT_ACC_SPRITES, PicoIn.opt, POPT_ACC_SPRITES),
|
||||
mee_onoff("autoload savestates", MA_OPT_AUTOLOAD_SAVE, g_autostateld_opt, 1),
|
||||
mee_onoff("SDL fullscreen mode", MA_OPT_VOUT_FULL, plat_target.vout_fullscreen, 1),
|
||||
mee_end,
|
||||
};
|
||||
|
||||
|
|
|
@ -40,6 +40,7 @@ typedef enum
|
|||
MA_OPT_INTERLACED, /* giz */
|
||||
MA_OPT_TEARING_FIX, /* wiz */
|
||||
MA_OPT_VOUT_MODE,
|
||||
MA_OPT_VOUT_FULL,
|
||||
MA_OPT_AUTOLOAD_SAVE,
|
||||
MA_OPT_SOUND_FILTER,
|
||||
MA_OPT_SOUND_ALPHA,
|
||||
|
|
|
@ -128,8 +128,6 @@ static int clear_buf_cnt, clear_stat_cnt;
|
|||
void plat_video_set_size(int w, int h)
|
||||
{
|
||||
if (area.w != w || area.h != h) {
|
||||
area = (struct area) { w, h };
|
||||
|
||||
if (plat_sdl_change_video_mode(w, h, 0) < 0) {
|
||||
// failed, revert to original resolution
|
||||
plat_sdl_change_video_mode(g_screen_width, g_screen_height, 0);
|
||||
|
@ -141,6 +139,7 @@ void plat_video_set_size(int w, int h)
|
|||
g_screen_ppitch = w;
|
||||
g_screen_ptr = plat_sdl_screen->pixels;
|
||||
}
|
||||
area = (struct area) { w, h };
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -193,7 +192,7 @@ void plat_video_clear_status(void)
|
|||
void plat_video_clear_buffers(void)
|
||||
{
|
||||
if (plat_sdl_overlay != NULL || plat_sdl_gl_active)
|
||||
memset(shadow_fb, 0, plat_sdl_screen->w*plat_sdl_screen->h * 2);
|
||||
memset(shadow_fb, 0, g_menuscreen_w * g_menuscreen_h * 2);
|
||||
else {
|
||||
memset(g_screen_ptr, 0, plat_sdl_screen->w*plat_sdl_screen->h * 2);
|
||||
clear_buf_cnt = 3; // do it thrice in case of triple buffering
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
#include "warm.h"
|
||||
#include "plat.h"
|
||||
|
||||
#include <pico/pico.h>
|
||||
#include <pico/pico_int.h>
|
||||
|
||||
/* GP2X local */
|
||||
int gp2x_current_bpp;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue