X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=Pico%2FPico.h;h=8caf109ad41189a464b7e0d3945b551940d2a6e5;hb=07abbab17a9baab5eeabe30767b0336326049994;hp=8398e7491c27fef2ba2233f724e2810d1a940ad9;hpb=1e6b5e39f45341524d90a4c71776e92a6d2d6fe5;p=picodrive.git diff --git a/Pico/Pico.h b/Pico/Pico.h index 8398e74..8caf109 100644 --- a/Pico/Pico.h +++ b/Pico/Pico.h @@ -48,10 +48,15 @@ void mp3_update(int *buffer, int length, int stereo); #define POPT_EN_SVP_DRC (1<<17) #define POPT_DIS_SPRITE_LIM (1<<18) extern int PicoOpt; // bitfield +#define PAHW_MCD (1<<0) +#define PAHW_32X (1<<1) +#define PAHW_SVP (1<<2) +#define PAHW_PICO (1<<3) +extern int PicoAHW; // Pico active hw extern int PicoVer; -extern int PicoSkipFrame; // skip rendering frame, but still do sound (if enabled) and emulation stuff +extern int PicoSkipFrame; // skip rendering frame, but still do sound (if enabled) and emulation stuff extern int PicoRegionOverride; // override the region detection 0: auto, 1: Japan NTSC, 2: Japan PAL, 4: US, 8: Europe -extern int PicoAutoRgnOrder; // packed priority list of regions, for example 0x148 means this detection order: EUR, USA, JAP +extern int PicoAutoRgnOrder; // packed priority list of regions, for example 0x148 means this detection order: EUR, USA, JAP extern int PicoSVPCycles; int PicoInit(void); void PicoExit(void); @@ -62,8 +67,9 @@ void PicoFrameDrawOnly(void); extern int PicoPad[2]; // Joypads, format is MXYZ SACB RLDU extern void (*PicoWriteSound)(int len); // called once per frame at the best time to send sound buffer (PsndOut) to hardware extern void (*PicoMessage)(const char *msg); // callback to output text message from emu -typedef enum { PS_PAL, PS_40_CELL, PS_240_LINES } pstat_t; -int PicoGetStat(pstat_t which); +typedef enum { PI_ROM, PI_ISPAL, PI_IS40_CELL, PI_IS240_LINES } pint_t; +typedef union { int vint; void *vptr; } pint_ret_t; +void PicoGetInternal(pint_t which, pint_ret_t *ret); // cd/Pico.c extern void (*PicoMCDopenTray)(void); @@ -71,14 +77,19 @@ extern int (*PicoMCDcloseTray)(void); extern int PicoCDBuffers; // Pico/Pico.c +#define XPCM_BUFFER_SIZE (320+160) typedef struct { int pen_pos[2]; int page; // internal - int fifo_bytes; + int fifo_bytes; // bytes in FIFO + int fifo_bytes_prev; + int fifo_line_bytes; // float part, << 16 int line_counter; - unsigned int r1, r12; + unsigned short r1, r12; + unsigned char xpcm_buffer[XPCM_BUFFER_SIZE+4]; + unsigned char *xpcm_ptr; } picohw_state; extern picohw_state PicoPicohw;