Merge "intrabc: Add odd-pel support for 444." into nextgen
This commit is contained in:
commit
7944249b80
@ -1458,6 +1458,7 @@ static void intrabc_search(VP9_COMP *cpi, MACROBLOCK *x,
|
|||||||
int mi_row, int mi_col,
|
int mi_row, int mi_col,
|
||||||
int_mv *tmp_mv, int *rate_mv) {
|
int_mv *tmp_mv, int *rate_mv) {
|
||||||
const VP9_COMMON *cm = &cpi->common;
|
const VP9_COMMON *cm = &cpi->common;
|
||||||
|
struct macroblockd_plane *pd = x->e_mbd.plane;
|
||||||
int bestsme = INT_MAX;
|
int bestsme = INT_MAX;
|
||||||
int step_param;
|
int step_param;
|
||||||
int sadpb = x->sadperbit16;
|
int sadpb = x->sadperbit16;
|
||||||
@ -1519,6 +1520,7 @@ static void intrabc_search(VP9_COMP *cpi, MACROBLOCK *x,
|
|||||||
assert(tmp_mv->as_int != 0);
|
assert(tmp_mv->as_int != 0);
|
||||||
|
|
||||||
if (bestsme < INT_MAX) {
|
if (bestsme < INT_MAX) {
|
||||||
|
if (pd[1].subsampling_x != 0 || pd[1].subsampling_y != 0) {
|
||||||
#if ODD_PEL_DV
|
#if ODD_PEL_DV
|
||||||
if (tmp_mv->as_mv.col > -w) {
|
if (tmp_mv->as_mv.col > -w) {
|
||||||
assert(tmp_mv->as_mv.row <= -h);
|
assert(tmp_mv->as_mv.row <= -h);
|
||||||
@ -1526,19 +1528,19 @@ static void intrabc_search(VP9_COMP *cpi, MACROBLOCK *x,
|
|||||||
tmp_mv->as_mv.row = tmp_mv->as_mv.row / 2 * 2;
|
tmp_mv->as_mv.row = tmp_mv->as_mv.row / 2 * 2;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
assert(tmp_mv->as_mv.row <= 8*8 - h);
|
assert(tmp_mv->as_mv.row <= 8 * 8 - h);
|
||||||
if (tmp_mv->as_mv.row == 8*8 - h - 1) {
|
if (tmp_mv->as_mv.row == 8 * 8 - h - 1) {
|
||||||
tmp_mv->as_mv.row = tmp_mv->as_mv.row / 2 * 2;
|
tmp_mv->as_mv.row = tmp_mv->as_mv.row / 2 * 2;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
tmp_mv->as_mv.row = tmp_mv->as_mv.row / 2 * 2;
|
||||||
|
tmp_mv->as_mv.col = tmp_mv->as_mv.col / 2 * 2;
|
||||||
|
#endif // ODD_PEL_DV
|
||||||
|
} else {
|
||||||
tmp_mv->as_mv.row *= 8;
|
tmp_mv->as_mv.row *= 8;
|
||||||
tmp_mv->as_mv.col *= 8;
|
tmp_mv->as_mv.col *= 8;
|
||||||
#else
|
}
|
||||||
tmp_mv->as_mv.row /= 2;
|
|
||||||
tmp_mv->as_mv.col /= 2;
|
|
||||||
tmp_mv->as_mv.row *= 16;
|
|
||||||
tmp_mv->as_mv.col *= 16;
|
|
||||||
#endif // ODD_PEL_DV
|
|
||||||
}
|
}
|
||||||
*rate_mv = vp9_mv_bit_cost(&tmp_mv->as_mv, &ref_mv,
|
*rate_mv = vp9_mv_bit_cost(&tmp_mv->as_mv, &ref_mv,
|
||||||
x->nmvjointcost, x->ndvcost, MV_COST_WEIGHT);
|
x->nmvjointcost, x->ndvcost, MV_COST_WEIGHT);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user