Updated our source code header to explicitly mention that we are GPL v2 or
[Rockbox.git] / apps / plugins / mpegplayer / mpeg_settings.h
blobd00dc197cbbe3c7a62838edf0f7dbce24bb46dd5
2 #include "plugin.h"
4 #define SETTINGS_VERSION 5
5 #define SETTINGS_MIN_VERSION 1
6 #define SETTINGS_FILENAME "mpegplayer.cfg"
8 #if defined(TOSHIBA_GIGABEAT_F) || defined(SANSA_E200) || defined(SANSA_C200) \
9 || defined (IRIVER_H10)
10 #define MPEG_OPTION_DITHERING_ENABLED 1
11 #endif
13 #ifndef MPEG_OPTION_DITHERING_ENABLED
14 #define MPEG_OPTION_DITHERING_ENABLED 0
15 #endif
17 enum mpeg_option_id
19 #if MPEG_OPTION_DITHERING_ENABLED
20 MPEG_OPTION_DITHERING,
21 #endif
22 MPEG_OPTION_DISPLAY_FPS,
23 MPEG_OPTION_LIMIT_FPS,
24 MPEG_OPTION_SKIP_FRAMES,
25 #ifdef HAVE_BACKLIGHT_BRIGHTNESS
26 MPEG_OPTION_BACKLIGHT_BRIGHTNESS,
27 #endif
30 enum mpeg_audio_option_id
32 MPEG_AUDIO_TONE_CONTROLS,
33 MPEG_AUDIO_CHANNEL_MODES,
34 MPEG_AUDIO_CROSSFEED,
35 MPEG_AUDIO_EQUALIZER,
36 MPEG_AUDIO_DITHERING,
39 enum mpeg_resume_id
41 MPEG_RESUME_MENU_ALWAYS = 0,
42 MPEG_RESUME_MENU_IF_INCOMPLETE,
43 MPEG_RESUME_RESTART,
44 MPEG_RESUME_ALWAYS,
45 MPEG_RESUME_NUM_OPTIONS,
48 enum mpeg_start_id
50 MPEG_START_RESTART,
51 MPEG_START_RESUME,
52 MPEG_START_SEEK,
53 MPEG_START_SETTINGS,
54 MPEG_START_QUIT,
55 MPEG_START_EXIT,
58 enum mpeg_menu_id
60 MPEG_MENU_DISPLAY_SETTINGS,
61 MPEG_MENU_AUDIO_SETTINGS,
62 MPEG_MENU_ENABLE_START_MENU,
63 MPEG_MENU_CLEAR_RESUMES,
64 MPEG_MENU_QUIT,
67 struct mpeg_settings {
68 int showfps; /* flag to display fps */
69 int limitfps; /* flag to limit fps */
70 int skipframes; /* flag to skip frames */
71 int resume_options; /* type of resume action at start */
72 int resume_count; /* total # of resumes in config file */
73 int resume_time; /* resume time for current mpeg (in half minutes) */
74 char resume_filename[MAX_PATH]; /* filename of current mpeg */
75 #if MPEG_OPTION_DITHERING_ENABLED
76 int displayoptions;
77 #endif
78 /* Audio options - simple on/off specification */
79 int tone_controls;
80 int channel_modes;
81 int crossfeed;
82 int equalizer;
83 int dithering;
84 /* Backlight options */
85 #ifdef HAVE_BACKLIGHT_BRIGHTNESS
86 int backlight_brightness;
87 #endif
90 extern struct mpeg_settings settings;
92 int mpeg_start_menu(uint32_t duration);
94 enum
96 MPEG_MENU_HIDE_QUIT_ITEM = 0x1, /* Don't show the quit item */
99 int mpeg_menu(unsigned flags);
100 void mpeg_menu_sysevent_clear(void);
101 long mpeg_menu_sysevent(void);
102 int mpeg_menu_sysevent_callback(int btn, int menu);
103 void mpeg_menu_sysevent_handle(void);
105 void init_settings(const char* filename);
106 void save_settings(void);
108 #ifdef HAVE_BACKLIGHT_BRIGHTNESS
109 void mpeg_backlight_update_brightness(int value);
110 #endif