6 // Configuration and command line parsing
7 void S9xLoadConfig(int argc, char ** argv);
8 void S9xUnloadConfig();
9 void S9xSetRomFile(const char * file);
10 extern struct config {
11 /** Unfreeze from .frz.gz snapshot on start */
13 /** Freeze to .frz.gz on exit */
15 /** Create fullscreen surface */
17 /** Name of the scaler to use or NULL for default */
19 /** Audio output enabled */
21 /** Speedhacks file to use */
23 /** Enable touchscreen controls */
24 bool touchscreenInput;
25 /** Display touchscreen controls grid */
27 /** If true, next time the main loop is entered application will close */
29 /** Current scancode->joypad mapping */
30 unsigned short joypad1Mapping[256];
31 unsigned short joypad2Mapping[256];
32 unsigned char action[256];
37 /** Size of the GUI Window */
38 unsigned short Width, Height;
39 /** Size of the (scaled) rendering area, relative to window. */
40 unsigned short RenderX, RenderY, RenderW, RenderH;
45 void S9xInitDisplay(int argc, char **argv);
46 void S9xDeinitDisplay();
47 void S9xVideoToggleFullscreen();
48 void S9xSetTitle (const char *title);
51 void S9xInitAudioOutput();
52 void S9xDeinitAudioOutput();
53 void S9xAudioOutputEnable(bool enable);
56 void S9xInitInputDevices();
57 void S9xDeinitInputDevices();
58 void S9xInputScreenChanged();
59 void S9xInputScreenDraw(int pixelSize, void * buffer, int pitch);
60 void S9xProcessEvents(bool block);
64 #define kActionQuit (1U << 0)
65 #define kActionToggleFullscreen (1U << 1)
66 #define kActionQuickLoad1 (1U << 2)
67 #define kActionQuickSave1 (1U << 3)
68 #define kActionQuickLoad2 (1U << 4)
69 #define kActionQuickSave2 (1U << 5)
71 void S9xDoAction(unsigned char action);