summaryrefslogtreecommitdiff
path: root/apps/main.c
diff options
context:
space:
mode:
authorJörg Hohensohn <hohensoh@rockbox.org>2004-01-05 20:42:51 +0000
committerJörg Hohensohn <hohensoh@rockbox.org>2004-01-05 20:42:51 +0000
commitf993365447d8dc5bb28c76a003cecd045c3abaf7 (patch)
tree19d4a2cfebd7e0f43c85559c2e88114fd4ba3223 /apps/main.c
parent974c2f0d43c1ebc786854f48f15ccaea7803d8f0 (diff)
downloadrockbox-f993365447d8dc5bb28c76a003cecd045c3abaf7.tar.gz
rockbox-f993365447d8dc5bb28c76a003cecd045c3abaf7.zip
Moved the low-level playback functionality into a new, separate module "mp3_playback". This e.g. allows to export a memory playback API to the plugins, opens the door to games with sound, UI sounds, etc.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@4192 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/main.c')
-rw-r--r--apps/main.c35
1 files changed, 19 insertions, 16 deletions
diff --git a/apps/main.c b/apps/main.c
index 04154f54fe..d6be594d07 100644
--- a/apps/main.c
+++ b/apps/main.c
@@ -37,6 +37,7 @@
37#include "serial.h" 37#include "serial.h"
38#endif 38#endif
39#include "mpeg.h" 39#include "mpeg.h"
40#include "mp3_playback.h"
40#include "main_menu.h" 41#include "main_menu.h"
41#include "thread.h" 42#include "thread.h"
42#include "settings.h" 43#include "settings.h"
@@ -78,14 +79,15 @@ void init(void)
78 sleep(HZ/2); 79 sleep(HZ/2);
79 tree_init(); 80 tree_init();
80 playlist_init(); 81 playlist_init();
81 mpeg_init( global_settings.volume, 82 mp3_init( global_settings.volume,
82 global_settings.bass, 83 global_settings.bass,
83 global_settings.treble, 84 global_settings.treble,
84 global_settings.balance, 85 global_settings.balance,
85 global_settings.loudness, 86 global_settings.loudness,
86 global_settings.bass_boost, 87 global_settings.bass_boost,
87 global_settings.avc, 88 global_settings.avc,
88 global_settings.channel_config ); 89 global_settings.channel_config );
90 mpeg_init();
89 while (button_get(false) != 0) 91 while (button_get(false) != 0)
90 ; /* Empty the keyboard buffer */ 92 ; /* Empty the keyboard buffer */
91} 93}
@@ -197,14 +199,15 @@ void init(void)
197 199
198 /* No buffer allocation (see buffer.c) may take place after the call to 200 /* No buffer allocation (see buffer.c) may take place after the call to
199 mpeg_init() since the mpeg thread takes the rest of the buffer space */ 201 mpeg_init() since the mpeg thread takes the rest of the buffer space */
200 mpeg_init( global_settings.volume, 202 mp3_init( global_settings.volume,
201 global_settings.bass, 203 global_settings.bass,
202 global_settings.treble, 204 global_settings.treble,
203 global_settings.balance, 205 global_settings.balance,
204 global_settings.loudness, 206 global_settings.loudness,
205 global_settings.bass_boost, 207 global_settings.bass_boost,
206 global_settings.avc, 208 global_settings.avc,
207 global_settings.channel_config ); 209 global_settings.channel_config );
210 mpeg_init();
208 211
209 /* no auto-rolo on startup any more, but I leave it here for reference */ 212 /* no auto-rolo on startup any more, but I leave it here for reference */
210#if 0 213#if 0