diff options
| author | Björn Stenberg <bjorn@haxx.se> | 2003-03-07 09:24:56 +0000 |
|---|---|---|
| committer | Björn Stenberg <bjorn@haxx.se> | 2003-03-07 09:24:56 +0000 |
| commit | f75a774b14ff237aa87a345a54a2f14660938323 (patch) | |
| tree | 53fd50266b1de36cd72a8d9fa5566de82445e02e /apps | |
| parent | d3d290545bc9df22719f941094dde963a11b97b8 (diff) | |
| download | rockbox-f75a774b14ff237aa87a345a54a2f14660938323.zip rockbox-f75a774b14ff237aa87a345a54a2f14660938323.tar.gz rockbox-f75a774b14ff237aa87a345a54a2f14660938323.tar.bz2 rockbox-f75a774b14ff237aa87a345a54a2f14660938323.tar.xz | |
Use mp3buf for playlist loading instead of a dedicated buffer. Speeds up loading and saves 16 KB ram.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@3395 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
| -rw-r--r-- | apps/playlist.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/apps/playlist.c b/apps/playlist.c index 78b601e..c511629 100644 --- a/apps/playlist.c +++ b/apps/playlist.c @@ -40,9 +40,10 @@ static struct playlist_info playlist; #define QUEUE_FILE ROCKBOX_DIR "/.queue_file" -#define PLAYLIST_BUFFER_SIZE (AVERAGE_FILENAME_LENGTH*MAX_FILES_IN_DIR) +#define PLAYLIST_BUFFER_SIZE (&mp3end - &mp3buf[0]) -static unsigned char playlist_buffer[PLAYLIST_BUFFER_SIZE]; +static unsigned char* playlist_buffer = mp3buf; +extern unsigned char mp3buf[],mp3end; static int playlist_end_pos = 0; static char now_playing[MAX_PATH+1]; @@ -655,6 +656,8 @@ void add_indices_to_playlist(void) store_index = true; + mpeg_stop(); + while(1) { if(playlist.in_ram) { |