From d68d02ec115d464e40ee70fa117d0a43158c9376 Mon Sep 17 00:00:00 2001 From: Andree Buschmann Date: Sun, 8 May 2011 20:18:35 +0000 Subject: Move implementation of codec_get_buffer() to codec.c, make related variables static. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29839 a1c6a512-1295-4272-9138-f99709370657 --- apps/codec_thread.c | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) (limited to 'apps/codec_thread.c') diff --git a/apps/codec_thread.c b/apps/codec_thread.c index 7cf45c3..4801c4a 100644 --- a/apps/codec_thread.c +++ b/apps/codec_thread.c @@ -208,19 +208,6 @@ void codec_thread_do_callback(void (*fn)(void), unsigned int *id) /** --- codec API callbacks --- **/ -static void * codec_get_buffer(size_t *size) -{ - ssize_t s = CODEC_SIZE - codec_size; - void *buf = &codecbuf[codec_size]; - ALIGN_BUFFER(buf, s, CACHEALIGN_SIZE); - - if (s <= 0) - return NULL; - - *size = s; - return buf; -} - static void codec_pcmbuf_insert_callback( const void *ch1, const void *ch2, int count) { @@ -420,7 +407,7 @@ void codec_init_codec_api(void) { ci.dsp = (struct dsp_config *)dsp_configure(NULL, DSP_MYDSP, CODEC_IDX_AUDIO); - ci.codec_get_buffer = codec_get_buffer; + ci.codec_get_buffer = codeclib_get_buffer; ci.pcmbuf_insert = codec_pcmbuf_insert_callback; ci.set_elapsed = audio_codec_update_elapsed; ci.read_filebuf = codec_filebuf_callback; -- cgit v1.1