From 81bfc1c5dc85f118ba037c671b0d04ec8f458711 Mon Sep 17 00:00:00 2001 From: notaz Date: Mon, 14 Sep 2009 10:41:30 +0000 Subject: [PATCH] 32x: more wip git-svn-id: file:///home/notaz/opt/svn/PicoDrive/platform@774 be3aeb3a-fb24-0410-a615-afba39da0efa --- common/emu.c | 6 +++--- common/menu.c | 4 +++- gp2x/Makefile | 5 +++-- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/common/emu.c b/common/emu.c index 627c3be..cc450d8 100644 --- a/common/emu.c +++ b/common/emu.c @@ -514,6 +514,9 @@ int emu_reload_rom(char *rom_fname) shutdown_MCD(); PicoPatchUnload(); + PicoCartUnload(); + rom_loaded = 0; + PicoAHW = 0; if (media_type == PM_CD) @@ -558,9 +561,6 @@ int emu_reload_rom(char *rom_fname) menu_romload_prepare(used_rom_name); // also CD load - PicoCartUnload(); - rom_loaded = 0; - ret = PicoCartLoad(rom, &rom_data, &rom_size, (PicoAHW & PAHW_SMS) ? 1 : 0); pm_close(rom); if (ret != 0) { diff --git a/common/menu.c b/common/menu.c index adfacef..1788033 100644 --- a/common/menu.c +++ b/common/menu.c @@ -1752,11 +1752,12 @@ static void draw_text_debug(const char *str, int skip, int from) static void draw_frame_debug(void) { - char layer_str[48] = "layers: "; + char layer_str[48] = "layers: "; if (PicoDrawMask & PDRAW_LAYERB_ON) memcpy(layer_str + 8, "B", 1); if (PicoDrawMask & PDRAW_LAYERA_ON) memcpy(layer_str + 10, "A", 1); if (PicoDrawMask & PDRAW_SPRITES_LOW_ON) memcpy(layer_str + 12, "spr_lo", 6); if (PicoDrawMask & PDRAW_SPRITES_HI_ON) memcpy(layer_str + 19, "spr_hi", 6); + if (PicoDrawMask & PDRAW_32X_ON) memcpy(layer_str + 26, "32x", 4); memset(g_screen_ptr, 0, g_screen_width * g_screen_height * 2); pemu_forced_frame(0); @@ -1826,6 +1827,7 @@ static void debug_menu_loop(void) if (inp & PBTN_RIGHT) PicoDrawMask ^= PDRAW_LAYERA_ON; if (inp & PBTN_DOWN) PicoDrawMask ^= PDRAW_SPRITES_LOW_ON; if (inp & PBTN_UP) PicoDrawMask ^= PDRAW_SPRITES_HI_ON; + if (inp & PBTN_MA2) PicoDrawMask ^= PDRAW_32X_ON; if (inp & PBTN_MOK) { PsndOut = NULL; // just in case PicoSkipFrame = 1; diff --git a/gp2x/Makefile b/gp2x/Makefile index 8ccea30..8a061cb 100644 --- a/gp2x/Makefile +++ b/gp2x/Makefile @@ -116,8 +116,9 @@ vpath %.c = ../.. vpath %.s = ../.. vpath %.S = ../.. -DIRS = platform platform/gp2x platform/linux platform/common pico pico/cd pico/pico pico/sound \ - pico/carthw/svp zlib unzip cpu cpu/musashi cpu/Cyclone/proj cpu/Cyclone/tools cpu/mz80 cpu/DrZ80 +DIRS = platform platform/gp2x platform/linux platform/common pico pico/cd pico/pico pico/32x \ + pico/sound pico/carthw/svp zlib unzip cpu cpu/musashi cpu/Cyclone/proj cpu/Cyclone/tools \ + cpu/mz80 cpu/DrZ80 all: mkdirs PicoDrive -- 2.39.2