X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=Pico%2FPico.c;h=0e9ee6c2bf8a9198bc9f05773494b28020c319fb;hb=259ed0ea6635845527a3da94a67a6260463861e6;hp=71add131e6e7e99611bbceb8a85664169cc342bb;hpb=03a265e5ebabff7adbb4f97387f81e9b0428dbee;p=picodrive.git diff --git a/Pico/Pico.c b/Pico/Pico.c index 71add13..0e9ee6c 100644 --- a/Pico/Pico.c +++ b/Pico/Pico.c @@ -256,6 +256,7 @@ static int CheckIdle(void) static __inline void getSamples(int y) { #if SIMPLE_WRITE_SOUND + if (y != 224) return; PsndRender(0, PsndLen); if (PicoWriteSound) PicoWriteSound(PsndLen); PsndClear(); @@ -501,6 +502,17 @@ void PicoFrameDrawOnly(void) for (y=0;y<224;y++) PicoLine(y); } +int PicoGetStat(pstat_t which) +{ + switch (which) + { + case PS_PAL: return Pico.m.pal; + case PS_40_CELL: return Pico.video.reg[12]&1; + case PS_240_LINES: return Pico.m.pal && (Pico.video.reg[1]&8); + } + return 0; +} + // callback to output message from emu void (*PicoMessage)(const char *msg)=NULL;