summaryrefslogtreecommitdiff
path: root/apps/plugins/mpegplayer/mpeg2_internal.h
diff options
context:
space:
mode:
authorJens Arnold <amiconn@rockbox.org>2007-10-16 22:55:40 +0000
committerJens Arnold <amiconn@rockbox.org>2007-10-16 22:55:40 +0000
commitfc43b9df823af80dd1c9cf7dc1b5de6703944043 (patch)
treebb17b985d00d13bc6fce61823acbe50ed1e003b0 /apps/plugins/mpegplayer/mpeg2_internal.h
parent84f5c5c3e3590cb993f4cf2a7eba5979e3bc825b (diff)
downloadrockbox-fc43b9df823af80dd1c9cf7dc1b5de6703944043.tar.gz
rockbox-fc43b9df823af80dd1c9cf7dc1b5de6703944043.zip
Mpegplayer: Assembler optimised IDCT for coldfire, based on FS #5995 by Karim Boucher. Put the IDCT block buffer in IRAM for better performance. The whole libmpeg2 decoder struct doesn't fit without throwing some libmad buffers out of IRAM, but then doesn't change performance significantly. Mpegplayer is quite usable now on X5; H300 is sort-of usable for widescreen.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15156 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins/mpegplayer/mpeg2_internal.h')
-rw-r--r--apps/plugins/mpegplayer/mpeg2_internal.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/apps/plugins/mpegplayer/mpeg2_internal.h b/apps/plugins/mpegplayer/mpeg2_internal.h
index 0c552b766f..1ec85c60f1 100644
--- a/apps/plugins/mpegplayer/mpeg2_internal.h
+++ b/apps/plugins/mpegplayer/mpeg2_internal.h
@@ -20,6 +20,8 @@
20 * along with this program; if not, write to the Free Software 20 * along with this program; if not, write to the Free Software
21 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 21 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
22 */ 22 */
23
24#include "config.h" /* for Rockbox CPU_ #defines */
23 25
24/* macroblock modes */ 26/* macroblock modes */
25#define MACROBLOCK_INTRA 1 27#define MACROBLOCK_INTRA 1
@@ -92,7 +94,11 @@ struct mpeg2_decoder_s {
92 int16_t dc_dct_pred[3]; 94 int16_t dc_dct_pred[3];
93 95
94 /* DCT coefficients */ 96 /* DCT coefficients */
97#ifdef CPU_COLDFIRE
98 int16_t *DCTblock; /* put buffer separately to have it in IRAM */
99#else
95 int16_t DCTblock[64] ATTR_ALIGN(64); 100 int16_t DCTblock[64] ATTR_ALIGN(64);
101#endif
96 102
97 uint8_t * picture_dest[3]; 103 uint8_t * picture_dest[3];
98 void (* convert) (void * convert_id, uint8_t * const * src, 104 void (* convert) (void * convert_id, uint8_t * const * src,