Lines Matching refs:mv_limits
37 void vp9_set_mv_search_range(MvLimits *mv_limits, const MV *mv) { in vp9_set_mv_search_range() argument
50 if (mv_limits->col_min < col_min) mv_limits->col_min = col_min; in vp9_set_mv_search_range()
51 if (mv_limits->col_max > col_max) mv_limits->col_max = col_max; in vp9_set_mv_search_range()
52 if (mv_limits->row_min < row_min) mv_limits->row_min = row_min; in vp9_set_mv_search_range()
53 if (mv_limits->row_max > row_max) mv_limits->row_max = row_max; in vp9_set_mv_search_range()
291 vp9_set_subpel_mv_search_range(&subpel_mv_limits, &x->mv_limits, ref_mv); \
775 vp9_set_subpel_mv_search_range(&subpel_mv_limits, &x->mv_limits, ref_mv); in vp9_find_best_sub_pixel_tree()
940 static INLINE int check_bounds(const MvLimits *mv_limits, int row, int col, in check_bounds() argument
942 return ((row - range) >= mv_limits->row_min) & in check_bounds()
943 ((row + range) <= mv_limits->row_max) & in check_bounds()
944 ((col - range) >= mv_limits->col_min) & in check_bounds()
945 ((col + range) <= mv_limits->col_max); in check_bounds()
948 static INLINE int is_mv_in(const MvLimits *mv_limits, const MV *mv) { in is_mv_in() argument
949 return (mv->col >= mv_limits->col_min) && (mv->col <= mv_limits->col_max) && in is_mv_in()
950 (mv->row >= mv_limits->row_min) && (mv->row <= mv_limits->row_max); in is_mv_in()
990 if (check_bounds(&x->mv_limits, br, bc, 1)) { in calc_int_cost_list()
1002 if (!is_mv_in(&x->mv_limits, &this_mv)) in calc_int_cost_list()
1039 clamp_mv(ref_mv, x->mv_limits.col_min, x->mv_limits.col_max, in vp9_pattern_search()
1040 x->mv_limits.row_min, x->mv_limits.row_max); in vp9_pattern_search()
1057 if (check_bounds(&x->mv_limits, br, bc, 1 << t)) { in vp9_pattern_search()
1070 if (!is_mv_in(&x->mv_limits, &this_mv)) continue; in vp9_pattern_search()
1099 if (check_bounds(&x->mv_limits, br, bc, 1 << s)) { in vp9_pattern_search()
1112 if (!is_mv_in(&x->mv_limits, &this_mv)) continue; in vp9_pattern_search()
1136 if (check_bounds(&x->mv_limits, br, bc, 1 << s)) { in vp9_pattern_search()
1153 if (!is_mv_in(&x->mv_limits, &this_mv)) continue; in vp9_pattern_search()
1209 clamp_mv(ref_mv, x->mv_limits.col_min, x->mv_limits.col_max, in vp9_pattern_search_sad()
1210 x->mv_limits.row_min, x->mv_limits.row_max); in vp9_pattern_search_sad()
1231 if (check_bounds(&x->mv_limits, br, bc, 1 << t)) { in vp9_pattern_search_sad()
1244 if (!is_mv_in(&x->mv_limits, &this_mv)) continue; in vp9_pattern_search_sad()
1273 if (check_bounds(&x->mv_limits, br, bc, 1 << s)) { in vp9_pattern_search_sad()
1286 if (!is_mv_in(&x->mv_limits, &this_mv)) continue; in vp9_pattern_search_sad()
1310 if (check_bounds(&x->mv_limits, br, bc, 1 << s)) { in vp9_pattern_search_sad()
1327 if (!is_mv_in(&x->mv_limits, &this_mv)) continue; in vp9_pattern_search_sad()
1347 if (check_bounds(&x->mv_limits, br, bc, 1 << s)) { in vp9_pattern_search_sad()
1360 if (!is_mv_in(&x->mv_limits, &this_mv)) continue; in vp9_pattern_search_sad()
1384 if (check_bounds(&x->mv_limits, br, bc, 1 << s)) { in vp9_pattern_search_sad()
1401 if (!is_mv_in(&x->mv_limits, &this_mv)) { in vp9_pattern_search_sad()
1431 if (check_bounds(&x->mv_limits, br, bc, 1)) { in vp9_pattern_search_sad()
1441 if (!is_mv_in(&x->mv_limits, &this_mv)) in vp9_pattern_search_sad()
1664 clamp_mv(&fcenter_mv, x->mv_limits.col_min, x->mv_limits.col_max, in exhuastive_mesh_search()
1665 x->mv_limits.row_min, x->mv_limits.row_max); in exhuastive_mesh_search()
1671 start_row = VPXMAX(-range, x->mv_limits.row_min - fcenter_mv.row); in exhuastive_mesh_search()
1672 start_col = VPXMAX(-range, x->mv_limits.col_min - fcenter_mv.col); in exhuastive_mesh_search()
1673 end_row = VPXMIN(range, x->mv_limits.row_max - fcenter_mv.row); in exhuastive_mesh_search()
1674 end_col = VPXMIN(range, x->mv_limits.col_max - fcenter_mv.col); in exhuastive_mesh_search()
1792 clamp_mv(best_full_mv, x->mv_limits.col_min, x->mv_limits.col_max, in vp9_diamond_search_sad_new()
1793 x->mv_limits.row_min, x->mv_limits.row_max); in vp9_diamond_search_sad_new()
1814 all_in &= ((best_full_mv->row + ss_mv[i].row) > x->mv_limits.row_min); in vp9_diamond_search_sad_new()
1815 all_in &= ((best_full_mv->row + ss_mv[i + 1].row) < x->mv_limits.row_max); in vp9_diamond_search_sad_new()
1816 all_in &= ((best_full_mv->col + ss_mv[i + 2].col) > x->mv_limits.col_min); in vp9_diamond_search_sad_new()
1817 all_in &= ((best_full_mv->col + ss_mv[i + 3].col) < x->mv_limits.col_max); in vp9_diamond_search_sad_new()
1854 if (is_mv_in(&x->mv_limits, &this_mv)) { in vp9_diamond_search_sad_new()
1944 clamp_mv(ref_mv, x->mv_limits.col_min, x->mv_limits.col_max, in vp9_diamond_search_sad_c()
1945 x->mv_limits.row_min, x->mv_limits.row_max); in vp9_diamond_search_sad_c()
1967 all_in &= ((best_mv->row + ss_mv[i].row) > x->mv_limits.row_min); in vp9_diamond_search_sad_c()
1968 all_in &= ((best_mv->row + ss_mv[i + 1].row) < x->mv_limits.row_max); in vp9_diamond_search_sad_c()
1969 all_in &= ((best_mv->col + ss_mv[i + 2].col) > x->mv_limits.col_min); in vp9_diamond_search_sad_c()
1970 all_in &= ((best_mv->col + ss_mv[i + 3].col) < x->mv_limits.col_max); in vp9_diamond_search_sad_c()
2005 if (is_mv_in(&x->mv_limits, &this_mv)) { in vp9_diamond_search_sad_c()
2030 if (is_mv_in(&x->mv_limits, &this_mv)) { in vp9_diamond_search_sad_c()
2254 vp9_set_subpel_mv_search_range(&subpel_mv_limits, &x->mv_limits, ref_mv); in vp9_int_pro_motion_estimation()
2479 const int all_in = ((best_full_mv->row - 1) > x->mv_limits.row_min) & in vp9_refining_search_sad_new()
2480 ((best_full_mv->row + 1) < x->mv_limits.row_max) & in vp9_refining_search_sad_new()
2481 ((best_full_mv->col - 1) > x->mv_limits.col_min) & in vp9_refining_search_sad_new()
2482 ((best_full_mv->col + 1) < x->mv_limits.col_max); in vp9_refining_search_sad_new()
2511 if (is_mv_in(&x->mv_limits, &mv)) { in vp9_refining_search_sad_new()
2558 const int all_in = ((ref_mv->row - 1) > x->mv_limits.row_min) & in vp9_refining_search_sad()
2559 ((ref_mv->row + 1) < x->mv_limits.row_max) & in vp9_refining_search_sad()
2560 ((ref_mv->col - 1) > x->mv_limits.col_min) & in vp9_refining_search_sad()
2561 ((ref_mv->col + 1) < x->mv_limits.col_max); in vp9_refining_search_sad()
2587 if (is_mv_in(&x->mv_limits, &mv)) { in vp9_refining_search_sad()
2628 clamp_mv(ref_mv, x->mv_limits.col_min, x->mv_limits.col_max, in vp9_refining_search_8p_c()
2629 x->mv_limits.row_min, x->mv_limits.row_max); in vp9_refining_search_8p_c()
2642 if (is_mv_in(&x->mv_limits, &mv)) { in vp9_refining_search_8p_c()