diff options
author | hkuang <hkuang@google.com> | 2014-02-04 14:50:20 -0800 |
---|---|---|
committer | Gerrit Code Review <gerrit@gerrit.golo.chromium.org> | 2014-02-04 14:50:20 -0800 |
commit | 948fe9338e68257e34eaca62c66d08f1eafa9921 (patch) | |
tree | 4f35881b33468c400ee70791fbe65ec1453890dc | |
parent | 71faaa5b587a3d8356a24585750d18ba5a18501f (diff) | |
parent | b0fec6ab4a61ded1ab2ade188987631f53c4e9c1 (diff) | |
download | libvpx-948fe9338e68257e34eaca62c66d08f1eafa9921.tar libvpx-948fe9338e68257e34eaca62c66d08f1eafa9921.tar.gz libvpx-948fe9338e68257e34eaca62c66d08f1eafa9921.tar.bz2 libvpx-948fe9338e68257e34eaca62c66d08f1eafa9921.zip |
Merge "With on demand border extension, clamping the MV is not longer needed."
-rw-r--r-- | vp9/common/vp9_reconinter.c | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/vp9/common/vp9_reconinter.c b/vp9/common/vp9_reconinter.c index cc70e4cc0..db20f19d9 100644 --- a/vp9/common/vp9_reconinter.c +++ b/vp9/common/vp9_reconinter.c @@ -269,21 +269,15 @@ static void dec_build_inter_predictors(MACROBLOCKD *xd, int plane, int block, ? (plane == 0 ? mi->bmi[block].as_mv[ref].as_mv : mi_mv_pred_q4(mi, ref)) : mi->mbmi.mv[ref].as_mv; - - // TODO(jkoleszar): This clamping is done in the incorrect place for the - // scaling case. It needs to be done on the scaled MV, not the pre-scaling - // MV. Note however that it performs the subsampling aware scaling so - // that the result is always q4. - // mv_precision precision is MV_PRECISION_Q4. - const MV mv_q4 = clamp_mv_to_umv_border_sb(xd, &mv, bw, bh, - pd->subsampling_x, - pd->subsampling_y); - MV32 scaled_mv; int xs, ys, x0, y0, x0_16, y0_16, x1, y1, frame_width, frame_height, subpel_x, subpel_y, buf_stride; uint8_t *ref_frame, *buf_ptr; const YV12_BUFFER_CONFIG *ref_buf = xd->block_refs[ref]->buf; + const MV mv_q4 = { + mv.row * (1 << (1 - pd->subsampling_y)), + mv.col * (1 << (1 - pd->subsampling_x)) + }; // Get reference frame pointer, width and height. if (plane == 0) { |