comparison rv34.c @ 9168:5de43b1eb9f4 libavcodec

Correct MV prediction for B-frame blocks in RV4 decoder
author kostya
date Sun, 15 Mar 2009 08:21:42 +0000
parents 9f96409c5134
children 54bc8a2727b0
comparison
equal deleted inserted replaced
9167:fd8b4aa6e493 9168:5de43b1eb9f4
531 if((r->avail_cache[5-4] & type) & mask){ 531 if((r->avail_cache[5-4] & type) & mask){
532 B[0] = cur_pic->motion_val[dir][mv_pos - s->b8_stride][0]; 532 B[0] = cur_pic->motion_val[dir][mv_pos - s->b8_stride][0];
533 B[1] = cur_pic->motion_val[dir][mv_pos - s->b8_stride][1]; 533 B[1] = cur_pic->motion_val[dir][mv_pos - s->b8_stride][1];
534 has_B = 1; 534 has_B = 1;
535 } 535 }
536 if((r->avail_cache[5-2] & type) & mask){ 536 if(r->avail_cache[5-4] && (r->avail_cache[5-2] & type) & mask){
537 C[0] = cur_pic->motion_val[dir][mv_pos - s->b8_stride + 2][0]; 537 C[0] = cur_pic->motion_val[dir][mv_pos - s->b8_stride + 2][0];
538 C[1] = cur_pic->motion_val[dir][mv_pos - s->b8_stride + 2][1]; 538 C[1] = cur_pic->motion_val[dir][mv_pos - s->b8_stride + 2][1];
539 has_C = 1; 539 has_C = 1;
540 }else if((s->mb_x+1) == s->mb_width && (r->avail_cache[5-5] & type) & mask){ 540 }else if((s->mb_x+1) == s->mb_width && (r->avail_cache[5-5] & type) & mask){
541 C[0] = cur_pic->motion_val[dir][mv_pos - s->b8_stride - 1][0]; 541 C[0] = cur_pic->motion_val[dir][mv_pos - s->b8_stride - 1][0];