diff options
author | Linus Nielsen Feltzing <linus@haxx.se> | 2002-08-08 14:51:58 +0000 |
---|---|---|
committer | Linus Nielsen Feltzing <linus@haxx.se> | 2002-08-08 14:51:58 +0000 |
commit | fe8a7e7f50bd36d846211909c337fe2ab6354b8b (patch) | |
tree | c2959ecd222b7abbd722677ff9e9bbed73108180 /firmware/mpeg.c | |
parent | 235d9d2565517ec73451390713a443d4fbac000c (diff) |
Now handles watermark on MPEG_NEXT
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@1616 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/mpeg.c')
-rw-r--r-- | firmware/mpeg.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/firmware/mpeg.c b/firmware/mpeg.c index ce50115f05..23af9d480b 100644 --- a/firmware/mpeg.c +++ b/firmware/mpeg.c @@ -735,17 +735,20 @@ static void mpeg_thread(void) if ( num_tracks_in_memory() > 1 ) { int track_offset = (tag_read_idx+1) & MAX_ID3_TAGS_MASK; mp3buf_read = id3tags[track_offset]->mempos; - playing = true; - last_dma_tick = current_tick; init_dma(); - start_dma(); - track_change(); + last_dma_tick = current_tick; /* should we start reading more data? */ if(!filling && (get_unplayed_space() < MPEG_LOW_WATER)) { filling = true; queue_post(&mpeg_queue, MPEG_NEED_DATA, 0); + play_pending = true; + } else { + playing = true; + start_dma(); } + + track_change(); } else { reset_mp3_buffer(); |