From 024db0a766f9590baea73babfefff278c28a5b2c Mon Sep 17 00:00:00 2001 From: Pedro Vasconcelos Date: Fri, 27 May 2005 09:14:00 +0000 Subject: Basic optimizations of the Vorbis decoder for the ihp-1x0. Capable of real-time decoding with cpu freq at 120mhz. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@6527 a1c6a512-1295-4272-9138-f99709370657 --- apps/plugins/vorbis2wav.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'apps/plugins/vorbis2wav.c') diff --git a/apps/plugins/vorbis2wav.c b/apps/plugins/vorbis2wav.c index 93ec4cfe69..01815ab1ca 100644 --- a/apps/plugins/vorbis2wav.c +++ b/apps/plugins/vorbis2wav.c @@ -16,7 +16,7 @@ * KIND, either express or implied. * ****************************************************************************/ - +#include "kernel.h" #include "plugin.h" #if (CONFIG_HWCODEC == MASNONE) @@ -86,6 +86,10 @@ extern char iramstart[]; extern char iramend[]; #endif + +/* reserve the PCM buffer in the IRAM area */ +static char pcmbuf[4096] IDATA_ATTR; + /* this is the plugin entry point */ enum plugin_status plugin_start(struct plugin_api* api, void* file) { @@ -97,7 +101,6 @@ enum plugin_status plugin_start(struct plugin_api* api, void* file) long n; int current_section; int eof; - static char pcmbuf[4096]; #if BYTE_ORDER == BIG_ENDIAN int i; char x; @@ -121,6 +124,7 @@ enum plugin_status plugin_start(struct plugin_api* api, void* file) return PLUGIN_ERROR; } + /* Create a decoder instance */ callbacks.read_func=read_handler; @@ -171,7 +175,6 @@ enum plugin_status plugin_start(struct plugin_api* api, void* file) close_wav(&file_info); rb->splash(HZ*2, true, "FINISHED!"); - return PLUGIN_OK; } #endif /* CONFIG_HWCODEC == MASNONE */ -- cgit v1.2.3