From: Kostya Shishkov Date: Sat, 24 Feb 2018 14:04:25 +0000 (+0100) Subject: h263: add missing calls for backward MV predictor keeper X-Git-Url: https://git.nihav.org/?a=commitdiff_plain;h=d609e5d5467cbb8392137343f1a7fceaa8debf2c;p=nihav.git h263: add missing calls for backward MV predictor keeper --- diff --git a/src/codecs/h263/decoder.rs b/src/codecs/h263/decoder.rs index cba6ef9..85d9eea 100644 --- a/src/codecs/h263/decoder.rs +++ b/src/codecs/h263/decoder.rs @@ -365,9 +365,15 @@ impl H263BaseDecoder { bdsp.idct(&mut blk[i]); } blockdsp::add_blocks(&mut buf, mb_x, mb_y, &blk); + if is_b { + mvi2.set_zero_mv(mb_x); + } } else if binfo.mode != Type::B { self.mv_data.push(BlockMVInfo::Inter_1MV(ZERO_MV)); mvi.set_zero_mv(mb_x); + if is_b { + mvi2.set_zero_mv(mb_x); + } if let Some(ref srcbuf) = self.ipbs.get_lastref() { bdsp.copy_blocks(&mut buf, srcbuf, mb_x * 16, mb_y * 16, 16, 16, ZERO_MV); } @@ -483,6 +489,9 @@ impl H263BaseDecoder { } } mvi.update_row(); + if is_b { + mvi2.update_row(); + } cbpi.update_row(); sstate.new_row(); }