From 6d3946fe53fe059226e923b8a01fa31cb13f9ad5 Mon Sep 17 00:00:00 2001 From: Kostya Shishkov Date: Mon, 27 Jan 2020 18:14:08 +0100 Subject: [PATCH] vp5: fix chroma MV --- nihav-duck/src/codecs/vp5.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nihav-duck/src/codecs/vp5.rs b/nihav-duck/src/codecs/vp5.rs index 1cd6531..7ba6d2a 100644 --- a/nihav-duck/src/codecs/vp5.rs +++ b/nihav-duck/src/codecs/vp5.rs @@ -221,7 +221,7 @@ impl VP56Parser for VP5BR { let (sx, sy, mx, my) = if (plane != 1) && (plane != 2) { (mv.x >> 1, mv.y >> 1, mv.x & 1, mv.y & 1) } else { - (mv.x >> 2, mv.y >> 2, (mv.x / 2) & 1, (mv.y / 2) & 1) + (mv.x >> 2, mv.y >> 2, if (mv.x & 3) != 0 { 1 } else { 0 }, if (mv.y & 3) != 0 { 1 } else { 0 }) }; let mode1 = (mx as usize) + (my as usize) * 2; let mode = if (mode1 == 3) && (mv.x ^ mv.y < 0) { -- 2.39.5