diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2002-03-28 13:41:04 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2002-03-28 13:41:04 +0000 |
commit | 649c00c96d7044aed46d70623e47d7434318e6b9 (patch) | |
tree | 90601636422687ba1e0f307b7919bfcda92710dc /libavcodec/h263dec.c | |
parent | cf8039b2cf590416a6402b31b444b25e593d5d62 (diff) | |
download | ffmpeg-649c00c96d7044aed46d70623e47d7434318e6b9.tar.gz |
sizeof(s->block) isnt 64*6*2 anymore bugfix
mpeg12 decoding optimization
Originally committed as revision 364 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/h263dec.c')
-rw-r--r-- | libavcodec/h263dec.c | 25 |
1 files changed, 3 insertions, 22 deletions
diff --git a/libavcodec/h263dec.c b/libavcodec/h263dec.c index aa822800bd..de9919fdad 100644 --- a/libavcodec/h263dec.c +++ b/libavcodec/h263dec.c @@ -156,6 +156,7 @@ static int h263_decode_frame(AVCodecContext *avctx, if (s->mb_y && !s->h263_pred) { s->first_gob_line = h263_decode_gob_header(s); } + s->block_index[0]= s->block_wrap[0]*(s->mb_y*2 + 1) - 1; s->block_index[1]= s->block_wrap[0]*(s->mb_y*2 + 1); s->block_index[2]= s->block_wrap[0]*(s->mb_y*2 + 2) - 1; @@ -183,28 +184,8 @@ static int h263_decode_frame(AVCodecContext *avctx, s->y_dc_scale = 8; s->c_dc_scale = 8; } - -#ifdef HAVE_MMX - if (mm_flags & MM_MMX) { - asm volatile( - "pxor %%mm7, %%mm7 \n\t" - "movl $-128*6, %%eax \n\t" - "1: \n\t" - "movq %%mm7, (%0, %%eax) \n\t" - "movq %%mm7, 8(%0, %%eax) \n\t" - "movq %%mm7, 16(%0, %%eax) \n\t" - "movq %%mm7, 24(%0, %%eax) \n\t" - "addl $32, %%eax \n\t" - " js 1b \n\t" - : : "r" (((int)s->block)+128*6) - : "%eax" - ); - }else{ - memset(s->block, 0, sizeof(s->block)); - } -#else - memset(s->block, 0, sizeof(s->block)); -#endif + clear_blocks(s->block[0]); + s->mv_dir = MV_DIR_FORWARD; s->mv_type = MV_TYPE_16X16; if (s->h263_msmpeg4) { |