X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;ds=inline;f=Pico%2FPico.c;h=93d6876460f887e3fa5624e724b9fdd7889865eb;hb=d4ca252d929395352f581b532e9d3726da31d718;hp=6d9d525e171bd6dfb4a3908e28c565166e85a4a8;hpb=017512f2823405ea2d02fa04b4c0754d7c4cba65;p=picodrive.git diff --git a/Pico/Pico.c b/Pico/Pico.c index 6d9d525..93d6876 100644 --- a/Pico/Pico.c +++ b/Pico/Pico.c @@ -19,7 +19,7 @@ int PicoAutoRgnOrder = 0; int emustatus = 0; // rapid_ym2612, multi_ym_updates void (*PicoWriteSound)(int len) = NULL; // called at the best time to send sound buffer (PsndOut) to hardware void (*PicoResetHook)(void) = NULL; -void (*PicoLineHook)(void) = NULL; +void (*PicoLineHook)(int count) = NULL; struct PicoSRAM SRam = {0,}; int z80startCycle, z80stopCycle; // in 68k cycles @@ -364,6 +364,7 @@ static int PicoFrameSimple(void) SekRunM68k(cycles_68k_block); PicoRunZ80Simple(line, lines); + if (PicoLineHook) PicoLineHook(lines_step); line=lines; } @@ -377,6 +378,7 @@ static int PicoFrameSimple(void) lines += sects*lines_step; PicoRunZ80Simple(line, lines); + if (PicoLineHook) PicoLineHook(sects*lines_step); } // render screen @@ -440,6 +442,7 @@ static int PicoFrameSimple(void) SekRunM68k(cycles_68k_vblock); PicoRunZ80Simple(line, lines); + if (PicoLineHook) PicoLineHook(lines_step); line=lines; sects--; @@ -450,6 +453,7 @@ static int PicoFrameSimple(void) if (sects) { lines += sects*lines_step; PicoRunZ80Simple(line, lines); + if (PicoLineHook) PicoLineHook(sects*lines_step); } return 0; @@ -577,14 +581,6 @@ char *debugString(void) } #endif -#if 0 - { - FILE *f = fopen("zram", "wb"); - fwrite(Pico.zram, 1, 0x2000, f); - fclose(f); - } -#endif - return dstr; } #endif