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) || defined(COWON_D2) || defined(PHILIPS_HDD1630) \
10 || defined(SANSA_FUZE) || defined(SANSA_E200V2) || defined(TOSHIBA_GIGABEAT_S)
11 #define MPEG_OPTION_DITHERING_ENABLED 1
14 #ifndef MPEG_OPTION_DITHERING_ENABLED
15 #define MPEG_OPTION_DITHERING_ENABLED 0
20 #if MPEG_OPTION_DITHERING_ENABLED
21 MPEG_OPTION_DITHERING
,
23 MPEG_OPTION_DISPLAY_FPS
,
24 MPEG_OPTION_LIMIT_FPS
,
25 MPEG_OPTION_SKIP_FRAMES
,
26 #ifdef HAVE_BACKLIGHT_BRIGHTNESS
27 MPEG_OPTION_BACKLIGHT_BRIGHTNESS
,
31 enum mpeg_audio_option_id
33 MPEG_AUDIO_TONE_CONTROLS
,
34 MPEG_AUDIO_CHANNEL_MODES
,
42 MPEG_RESUME_MENU_ALWAYS
= 0,
43 MPEG_RESUME_MENU_IF_INCOMPLETE
,
46 MPEG_RESUME_NUM_OPTIONS
,
61 MPEG_SETTING_DISPLAY_SETTINGS
,
62 MPEG_SETTING_AUDIO_SETTINGS
,
63 MPEG_SETTING_ENABLE_START_MENU
,
64 MPEG_SETTING_CLEAR_RESUMES
,
74 struct mpeg_settings
{
75 int showfps
; /* flag to display fps */
76 int limitfps
; /* flag to limit fps */
77 int skipframes
; /* flag to skip frames */
78 int resume_options
; /* type of resume action at start */
79 int resume_count
; /* total # of resumes in config file */
80 int resume_time
; /* resume time for current mpeg (in half minutes) */
81 char resume_filename
[MAX_PATH
]; /* filename of current mpeg */
82 #if MPEG_OPTION_DITHERING_ENABLED
85 /* Audio options - simple on/off specification */
91 /* Backlight options */
92 #ifdef HAVE_BACKLIGHT_BRIGHTNESS
93 int backlight_brightness
;
97 extern struct mpeg_settings settings
;
99 int mpeg_start_menu(uint32_t duration
);
102 void mpeg_menu_sysevent_clear(void);
103 long mpeg_menu_sysevent(void);
104 int mpeg_menu_sysevent_callback(int btn
, const struct menu_item_ex
*menu
);
105 void mpeg_menu_sysevent_handle(void);
107 void init_settings(const char* filename
);
108 void save_settings(void);
110 #ifdef HAVE_BACKLIGHT_BRIGHTNESS
111 void mpeg_backlight_update_brightness(int value
);