1 #ifndef MDFN_FILE_H
2 #define MDFN_FILE_H
3 
4 #include <stdint.h>
5 
6 #define MDFNFILE_EC_NOTFOUND	1
7 #define MDFNFILE_EC_OTHER	2
8 
9 #ifdef __cplusplus
10 extern "C" {
11 #endif
12 
13 struct MDFNFILE
14 {
15    uint8_t *data;
16    uint64_t size;
17    char *ext;
18    uint64_t location;
19 };
20 
21 struct MDFNFILE *file_open(const char *path);
22 
23 int file_close(struct MDFNFILE *file);
24 
25 #ifdef __cplusplus
26 }
27 #endif
28 
29 #endif
30