ALL: Huge upstream synch + PerRom DelaySI & CountPerOp parameters
[mupen64plus-pandora.git] / source / mupen64plus-core / src / main / main.h
1 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
2  *   Mupen64plus - main.h                                                  *
3  *   Mupen64Plus homepage: http://code.google.com/p/mupen64plus/           *
4  *   Copyright (C) 2012 CasualJames                                        *
5  *   Copyright (C) 2002 Blight                                             *
6  *                                                                         *
7  *   This program is free software; you can redistribute it and/or modify  *
8  *   it under the terms of the GNU General Public License as published by  *
9  *   the Free Software Foundation; either version 2 of the License, or     *
10  *   (at your option) any later version.                                   *
11  *                                                                         *
12  *   This program is distributed in the hope that it will be useful,       *
13  *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
14  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
15  *   GNU General Public License for more details.                          *
16  *                                                                         *
17  *   You should have received a copy of the GNU General Public License     *
18  *   along with this program; if not, write to the                         *
19  *   Free Software Foundation, Inc.,                                       *
20  *   51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.          *
21  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
22
23 #ifndef __MAIN_H__
24 #define __MAIN_H__
25
26 #include "api/m64p_types.h"
27
28 /* globals */
29 extern m64p_handle g_CoreConfig;
30
31 extern int g_MemHasBeenBSwapped;
32 extern int g_EmulatorRunning;
33
34 extern m64p_frame_callback g_FrameCallback;
35
36 extern int delay_si;
37
38 const char* get_savestatepath(void);
39 const char* get_savesrampath(void);
40
41 void new_frame(void);
42 void new_vi(void);
43
44 int  main_set_core_defaults(void);
45 void main_message(m64p_msg_level level, unsigned int osd_corner, const char *format, ...);
46
47 m64p_error main_run(void);
48 void main_stop(void);
49 void main_toggle_pause(void);
50 void main_advance_one(void);
51
52 void main_speedup(int percent);
53 void main_speeddown(int percent);
54 void main_set_fastforward(int enable);
55
56 void main_take_next_screenshot(void);
57
58 void main_state_set_slot(int slot);
59 void main_state_inc_slot(void);
60 void main_state_load(const char *filename);
61 void main_state_save(int format, const char *filename);
62
63 m64p_error main_core_state_query(m64p_core_param param, int *rval);
64 m64p_error main_core_state_set(m64p_core_param param, int val);
65
66 m64p_error main_get_screen_size(int *width, int *height);
67 m64p_error main_read_screen(void *pixels, int bFront);
68
69 m64p_error main_volume_up(void);
70 m64p_error main_volume_down(void);
71 m64p_error main_volume_get_level(int *level);
72 m64p_error main_volume_set_level(int level);
73 m64p_error main_volume_mute(void);
74 int        main_volume_get_muted(void);
75
76 m64p_error main_reset(int do_hard_reset);
77
78 #endif /* __MAIN_H__ */
79