if (loaded_mp3 != f)\r
{\r
// printf("loading mp3... "); fflush(stdout);\r
+ if (PicoMessage != NULL)\r
+ {\r
+ fseek(f, 0, SEEK_END);\r
+ if (ftell(f) > 2*1024*1024)\r
+ PicoMessage("Loading MP3...");\r
+ }\r
fseek(f, 0, SEEK_SET);\r
fread(mp3_mem, 1, MP3_SIZE_MAX, f);\r
// if (feof(f)) printf("done.\n");\r
dprint = 1\r
#mz80 = 1\r
#debug_cyclone = 1\r
-asm_memory = 0 # TODO\r
+asm_memory = 1\r
asm_render = 1\r
asm_ym2612 = 1\r
asm_misc = 1\r
}\r
\r
\r
+static void emu_msg_cb(const char *msg);\r
+\r
void emu_Init(void)\r
{\r
// make temp buffer for alt renderer\r
mkdir("cfg", 0777);\r
\r
PicoInit();\r
+ PicoMessage = emu_msg_cb;\r
\r
// logf = fopen("log.txt", "w");\r
}\r
}\r
\r
\r
+static void emu_msg_cb(const char *msg)\r
+{\r
+ if ((PicoOpt&0x10)||!(currentConfig.EmuOpt&0x80)) {\r
+ // 8-bit renderers\r
+ gp2x_memset_all_buffers(320*232, 0xe0, 320*8);\r
+ osd_text(4, 232, msg);\r
+ gp2x_memcpy_all_buffers((char *)gp2x_screen+320*232, 320*232, 320*8);\r
+ } else {\r
+ // 16bit accurate renderer\r
+ gp2x_memset_all_buffers(320*232*2, 0, 320*8*2);\r
+ osd_text(4, 232, msg);\r
+ gp2x_memcpy_all_buffers((char *)gp2x_screen+320*232*2, 320*232*2, 320*8*2);\r
+ }\r
+ gettimeofday(¬iceMsgTime, 0);\r
+ noticeMsgTime.tv_sec -= 2;\r
+}\r
+\r
static void emu_state_cb(const char *str)\r
{\r
clearArea(0);\r
gp2x_text_out8(tl_x, (y+=10), "CD LEDs %s", (currentConfig.EmuOpt &0x0400)?"ON":"OFF"); // 3\r
gp2x_text_out8(tl_x, (y+=10), "CDDA audio (using mp3s) %s", (currentConfig.PicoOpt&0x0800)?"ON":"OFF"); // 4\r
gp2x_text_out8(tl_x, (y+=10), "PCM audio %s", (currentConfig.PicoOpt&0x0400)?"ON":"OFF"); // 5\r
- gp2x_text_out8(tl_x, (y+=10), "Better sync (slow) %s", (currentConfig.PicoOpt&0x2000)?"ON":"OFF"); // 6\r
+ gp2x_text_out8(tl_x, (y+=10), "Better sync (slower) %s", (currentConfig.PicoOpt&0x2000)?"ON":"OFF"); // 6\r
gp2x_text_out8(tl_x, (y+=10), "ReadAhead buffer %s", ra_buff); // 7\r
gp2x_text_out8(tl_x, (y+=10), "Done");\r
\r