[FFmpeg-cvslog] r14355 - trunk/libavcodec/ra288.c
vitor
subversion
Thu Jul 24 05:19:53 CEST 2008
Author: vitor
Date: Thu Jul 24 05:19:52 2008
New Revision: 14355
Log:
Simplify co(), use memcpy/memmove and colmult() when useful.
Modified:
trunk/libavcodec/ra288.c
Modified: trunk/libavcodec/ra288.c
==============================================================================
--- trunk/libavcodec/ra288.c (original)
+++ trunk/libavcodec/ra288.c Thu Jul 24 05:19:52 2008
@@ -141,19 +141,15 @@ static void co(int n, int i, int j, cons
float *st2, const float *table)
{
unsigned int x;
- const float *fp;
float buffer1[37];
float buffer2[37];
float work[111];
/* rotate and multiply */
- fp = st1 + i;
- for (x=0; x < n + i + j; x++) {
- if (x == n + j)
- fp=in;
- st1[x] = *(fp++);
- work[x] = table[x] * st1[x];
- }
+ memmove(st1 , st1 + i, (n + j)*sizeof(*st1));
+ memcpy (st1 + n + j, in , i *sizeof(*st1));
+
+ colmult(work, table, st1, n + i + j);
prodsum(buffer1, work + n , i, n);
prodsum(buffer2, work + n + i, j, n);
More information about the ffmpeg-cvslog
mailing list