diff options
| author | Linus Nielsen Feltzing <linus@haxx.se> | 2005-04-05 11:33:58 +0000 |
|---|---|---|
| committer | Linus Nielsen Feltzing <linus@haxx.se> | 2005-04-05 11:33:58 +0000 |
| commit | d34865a5307e7bf91d986036797423975ac828b4 (patch) | |
| tree | 41dcc1775f6cdc1d655f1eddadaabdf90c7ac22f /apps/talk.c | |
| parent | 6cf9d51b3374cdc436c45f165a10f607832126ee (diff) | |
| download | rockbox-d34865a5307e7bf91d986036797423975ac828b4.zip rockbox-d34865a5307e7bf91d986036797423975ac828b4.tar.gz rockbox-d34865a5307e7bf91d986036797423975ac828b4.tar.bz2 rockbox-d34865a5307e7bf91d986036797423975ac828b4.tar.xz | |
mp3buf renamed to audiobuf
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@6252 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/talk.c')
| -rw-r--r-- | apps/talk.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/apps/talk.c b/apps/talk.c index 2b97629..b6e2ec5 100644 --- a/apps/talk.c +++ b/apps/talk.c @@ -131,7 +131,7 @@ static void load_voicefile(void) goto load_err; file_size = filesize(filehandle); - if (file_size > mp3end - mp3buf) /* won't fit? */ + if (file_size > audiobufend - audiobuf) /* won't fit? */ goto load_err; #ifdef HAVE_MMC /* load only the header for now */ @@ -140,17 +140,17 @@ static void load_voicefile(void) load_size = file_size; #endif - got_size = read(filehandle, mp3buf, load_size); + got_size = read(filehandle, audiobuf, load_size); if (got_size == load_size /* success */ - && ((struct voicefile*)mp3buf)->table /* format check */ + && ((struct voicefile*)audiobuf)->table /* format check */ == offsetof(struct voicefile, index)) { - p_voicefile = (struct voicefile*)mp3buf; + p_voicefile = (struct voicefile*)audiobuf; /* thumbnail buffer is the remaining space behind */ - p_thumbnail = mp3buf + file_size; + p_thumbnail = audiobuf + file_size; p_thumbnail += (long)p_thumbnail % 2; /* 16-bit align */ - size_for_thumbnail = mp3end - p_thumbnail; + size_for_thumbnail = audiobufend - p_thumbnail; } else goto load_err; @@ -160,7 +160,7 @@ static void load_voicefile(void) load_size = (p_voicefile->id1_max + p_voicefile->id2_max) * sizeof(struct clip_entry); got_size = read(filehandle, - mp3buf + offsetof(struct voicefile, index), load_size); + audiobuf + offsetof(struct voicefile, index), load_size); if (got_size != load_size) /* read error */ goto load_err; #else @@ -356,7 +356,7 @@ static unsigned char* get_clip(long id, long* p_size) clipsize = p_voicefile->index[id].size; if (clipsize == 0) /* clip not included in voicefile */ return NULL; - clipbuf = mp3buf + p_voicefile->index[id].offset; + clipbuf = audiobuf + p_voicefile->index[id].offset; #ifdef HAVE_MMC /* dynamic loading, on demand */ if (!(clipsize & LOADED_MASK)) @@ -383,8 +383,8 @@ static void reset_state(void) { queue_write = queue_read = 0; /* reset the queue */ p_voicefile = NULL; /* indicate no voicefile (trashed) */ - p_thumbnail = mp3buf; /* whole space for thumbnail */ - size_for_thumbnail = mp3end - mp3buf; + p_thumbnail = audiobuf; /* whole space for thumbnail */ + size_for_thumbnail = audiobufend - audiobuf; p_silence = NULL; /* pause clip not accessible */ } |