Work around fix for a compilation error on Linux
[clinton/Virtual-Jaguar-Rx.git] / src / settings.h
1 //
2 // settings.h: Header file
3 //
4 // JPM = Jean-Paul Mari <djipi.mari@gmail.com>
5 //
6 // Who When What
7 // --- ---------- ------------------------------------------------------------
8 // JPM 06/19/2016 Soft debugger support
9 // JPM Sept./2018 Added the new Models and BIOS handler, and a screenshot settings
10 // JPM 10/10/2018 Added search paths in settings
11 // JPM 04/06/2019 Added ELF sections check
12 //
13
14 #ifndef __SETTINGS_H__
15 #define __SETTINGS_H__
16
17 // MAX_PATH isn't defined in stdlib.h on *nix, so we do it here...
18 #ifdef __GCCUNIX__
19 #include <limits.h>
20 #define MAX_PATH _POSIX_PATH_MAX
21 #else
22 #include <stdlib.h> // for MAX_PATH on MinGW/Darwin
23 // Kludge for Win64
24 #ifndef MAX_PATH
25 #define MAX_PATH _MAX_PATH // Urgh.
26 #endif
27 #endif
28 #include <stdint.h>
29
30 #define MaxMemory1BrowserWindow 4
31
32
33 // List the erase settings possibilities
34 enum
35 {
36 SETTINGS_NONE = 0,
37 SETTINGS_ALL,
38 SETTINGS_UI,
39 SETTINGS_ALPINE,
40 SETTINGS_DEBUGGER,
41 SETTINGS_END
42 };
43
44
45 // Key bindings settings structure
46 struct KBSettings
47 {
48 //char KBSettingName[100];
49 char KBSettingValue[100];
50 //char KBSettingDefaultValue[100];
51 };
52
53
54 // functions declarations
55 extern bool EraseSettings(char *Setting);
56
57
58 // Settings struct
59 struct VJSettings
60 {
61 bool useJoystick; // Joystick usage
62 int32_t joyport; // Joystick port
63 bool hardwareTypeNTSC; // Set to false for PAL, otherwise it is NTSC
64 bool useJaguarBIOS; // Use of any Jaguar BIOS
65 bool useRetailBIOS; // Use of Retail BIOS
66 bool useDevBIOS; // Use of Development BIOS
67 bool GPUEnabled; // Use of GPU
68 bool DSPEnabled; // Use of DSP
69 bool usePipelinedDSP;
70 bool fullscreen; // Emulator in full screen mode so video output display only
71 bool useOpenGL; // OpenGL support (always 'true')
72 uint32_t glFilter;
73 bool hardwareTypeAlpine; // Alpine mode
74 bool softTypeDebugger; // Soft type debugger mode
75 bool audioEnabled;
76 uint32_t frameSkip;
77 uint32_t renderType;
78 uint32_t refresh;
79 bool allowWritesToROM; // Allow writing to ROM cartdridge
80 uint32_t biosType; // Bios type used
81 uint32_t jaguarModel; // Jaguar model
82 size_t nbrdisasmlines; // Number of lines to show in the M68K tracing window
83 bool disasmopcodes;
84 bool displayHWlabels;
85 bool useFastBlitter;
86 bool displayFullSourceFilename;
87 bool ELFSectionsCheck;
88 size_t nbrmemory1browserwindow; // Number of memory browser windows
89 size_t DRAM_size; // DRAM size
90
91 // Keybindings in order of U, D, L, R, C, B, A, Op, Pa, 0-9, #, *
92 uint32_t p1KeyBindings[21];
93 uint32_t p2KeyBindings[21];
94
95 // Keybindings
96 KBSettings KBContent[100];
97
98 // Paths
99 char ROMPath[MAX_PATH];
100 //char jagBootPath[MAX_PATH];
101 //char CDBootPath[MAX_PATH];
102 char EEPROMPath[MAX_PATH];
103 char alpineROMPath[MAX_PATH];
104 char debuggerROMPath[MAX_PATH];
105 char absROMPath[MAX_PATH];
106 char screenshotPath[MAX_PATH];
107 char sourcefilesearchPaths[4096];
108 };
109
110 // Render types
111 enum { RT_NORMAL = 0, RT_TV = 1 };
112
113 // Jaguar models
114 enum { JAG_NULL_SERIES, JAG_K_SERIES, JAG_M_SERIES };
115
116 // BIOS types
117 enum { BT_NULL, BT_K_SERIES, BT_M_SERIES, BT_STUBULATOR_1, BT_STUBULATOR_2 };
118
119 // Exported variables
120 extern VJSettings vjs;
121
122 #endif // __SETTINGS_H__