Commit 41f088e0 authored by vitor's avatar vitor

Only one out of two values of gbuf1 is actually used. Make it half the size.

git-svn-id: file:///var/local/repositories/ffmpeg/trunk@13213 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 7e63b1ae
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
/* internal globals */ /* internal globals */
typedef struct { typedef struct {
unsigned int oldval; unsigned int oldval;
unsigned int gbuf1[8]; unsigned int gbuf1[4];
unsigned short gbuf2[120]; unsigned short gbuf2[120];
unsigned int *decptr; /* decoder ptr */ unsigned int *decptr; /* decoder ptr */
signed short *decsp; signed short *decsp;
...@@ -268,7 +268,6 @@ static void dec1(Real144_internal *glob, const int *data, const int *inp, ...@@ -268,7 +268,6 @@ static void dec1(Real144_internal *glob, const int *data, const int *inp,
short *ptr,*end; short *ptr,*end;
*(glob->decptr++) = rms(data, f); *(glob->decptr++) = rms(data, f);
glob->decptr++;
end = (ptr = glob->decsp) + (n * 10); end = (ptr = glob->decsp) + (n * 10);
while (ptr < end) while (ptr < end)
...@@ -367,7 +366,6 @@ static void dec2(Real144_internal *glob, const int *data, const int *inp, ...@@ -367,7 +366,6 @@ static void dec2(Real144_internal *glob, const int *data, const int *inp,
dec1(glob, data, inp, n, f); dec1(glob, data, inp, n, f);
} else { } else {
*(glob->decptr++) = rms(work, f); *(glob->decptr++) = rms(work, f);
glob->decptr++;
} }
glob->decsp += n * 10; glob->decsp += n * 10;
} }
...@@ -412,7 +410,7 @@ static int ra144_decode_frame(AVCodecContext * avctx, ...@@ -412,7 +410,7 @@ static int ra144_decode_frame(AVCodecContext * avctx,
/* do output */ /* do output */
for (b=0, c=0; c<4; c++) { for (b=0, c=0; c<4; c++) {
unsigned int gval = glob->gbuf1[c * 2]; unsigned int gval = glob->gbuf1[c];
unsigned short *gsp = glob->gbuf2 + b; unsigned short *gsp = glob->gbuf2 + b;
signed short output_buffer[40]; signed short output_buffer[40];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment