extern void (*PicoStateProgressCB)(const char *str);\r
\r
// Cart.c\r
-int PicoCartLoad(FILE *f,unsigned char **prom,unsigned int *psize);\r
+typedef enum\r
+{\r
+ PMT_UNCOMPRESSED = 0,\r
+ PMT_ZIP\r
+} pm_type;\r
+typedef struct\r
+{\r
+ void *file; /* file handle */\r
+ void *param; /* additional file related field */\r
+ unsigned int size; /* size */\r
+ pm_type type;\r
+} pm_file;\r
+pm_file *pm_open(const char *path);\r
+size_t pm_read(void *ptr, size_t bytes, pm_file *stream);\r
+int pm_seek(pm_file *stream, long offset, int whence);\r
+int pm_close(pm_file *fp);\r
+int PicoCartLoad(pm_file *f,unsigned char **prom,unsigned int *psize);\r
int PicoCartInsert(unsigned char *rom,unsigned int romsize);\r
-// notaz\r
-int CartLoadZip(const char *fname, unsigned char **prom, unsigned int *psize);\r
void Byteswap(unsigned char *data,int len);\r
// anotherguest\r
int PicoUnloadCart(unsigned char* romdata);\r