summaryrefslogtreecommitdiff
path: root/apps/playback.c
diff options
context:
space:
mode:
authorSteve Bavin <pondlife@pondlife.me>2007-10-02 07:47:43 +0000
committerSteve Bavin <pondlife@pondlife.me>2007-10-02 07:47:43 +0000
commit4d34457cd0a1958ff271bb2d87bfdba1432b678e (patch)
tree74619bcbf25da3d5503e7d010776f92f75f5bbc7 /apps/playback.c
parent227181deb0be5de2ddcf0d28f057f4175dc051b9 (diff)
downloadrockbox-4d34457cd0a1958ff271bb2d87bfdba1432b678e.zip
rockbox-4d34457cd0a1958ff271bb2d87bfdba1432b678e.tar.gz
rockbox-4d34457cd0a1958ff271bb2d87bfdba1432b678e.tar.bz2
rockbox-4d34457cd0a1958ff271bb2d87bfdba1432b678e.tar.xz
Thanks to Nico_P, struct track_info can now be internal to playback.c
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14947 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/playback.c')
-rw-r--r--apps/playback.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/apps/playback.c b/apps/playback.c
index c58c5a6..b80c683 100644
--- a/apps/playback.c
+++ b/apps/playback.c
@@ -222,6 +222,23 @@ static int buffer_state = BUFFER_STATE_TRASHED; /* Buffer state */
#define FILEBUFUSED RINGBUF_SUB(buf_widx, buf_ridx)
/* Track info structure about songs in the file buffer (A/C-) */
+struct track_info {
+ struct mp3entry id3; /* TAG metadata */
+ char *codecbuf; /* Pointer to codec buffer */
+ size_t codecsize; /* Codec length in bytes */
+ bool has_codec; /* Does this track have a codec on the buffer */
+
+ size_t buf_idx; /* Pointer to the track's buffer */
+ size_t filerem; /* Remaining bytes of file NOT in buffer */
+ size_t filesize; /* File total length */
+ size_t start_pos; /* Position to first bytes of file in buffer */
+ volatile size_t available; /* Available bytes to read from buffer */
+
+ bool taginfo_ready; /* Is metadata read */
+
+ bool event_sent; /* Was this track's buffered event sent */
+};
+
static struct track_info tracks[MAX_TRACK];
static volatile int track_ridx = 0; /* Track being decoded (A/C-) */
static int track_widx = 0; /* Track being buffered (A) */