Merge "Fix some more offset errors in sb8x8." into experimental
This commit is contained in:
Коммит
ec6cf519d1
|
@ -502,6 +502,12 @@ static INLINE int partition_plane_context(MACROBLOCKD *xd,
|
||||||
int above = 0, left = 0, i;
|
int above = 0, left = 0, i;
|
||||||
int boffset = mi_width_log2(BLOCK_SIZE_SB64X64) - bsl;
|
int boffset = mi_width_log2(BLOCK_SIZE_SB64X64) - bsl;
|
||||||
|
|
||||||
|
#if CONFIG_SB8X8
|
||||||
|
bs = 1 << (bsl - 1);
|
||||||
|
#else
|
||||||
|
bs = 1 << bsl;
|
||||||
|
#endif
|
||||||
|
|
||||||
assert(mi_width_log2(sb_type) == mi_height_log2(sb_type));
|
assert(mi_width_log2(sb_type) == mi_height_log2(sb_type));
|
||||||
assert(bsl >= 0);
|
assert(bsl >= 0);
|
||||||
assert(boffset >= 0);
|
assert(boffset >= 0);
|
||||||
|
|
|
@ -545,8 +545,8 @@ void vp9_build_interintra_predictors_sbuv(MACROBLOCKD *xd,
|
||||||
|
|
||||||
void vp9_build_intra_predictors_sby_s(MACROBLOCKD *xd,
|
void vp9_build_intra_predictors_sby_s(MACROBLOCKD *xd,
|
||||||
BLOCK_SIZE_TYPE bsize) {
|
BLOCK_SIZE_TYPE bsize) {
|
||||||
const int bwl = mi_width_log2(bsize), bw = MI_SIZE << bwl;
|
const int bwl = b_width_log2(bsize), bw = 4 << bwl;
|
||||||
const int bhl = mi_height_log2(bsize), bh = MI_SIZE << bhl;
|
const int bhl = b_height_log2(bsize), bh = 4 << bhl;
|
||||||
|
|
||||||
vp9_build_intra_predictors(xd->plane[0].dst.buf, xd->plane[0].dst.stride,
|
vp9_build_intra_predictors(xd->plane[0].dst.buf, xd->plane[0].dst.stride,
|
||||||
xd->plane[0].dst.buf, xd->plane[0].dst.stride,
|
xd->plane[0].dst.buf, xd->plane[0].dst.stride,
|
||||||
|
@ -558,8 +558,8 @@ void vp9_build_intra_predictors_sby_s(MACROBLOCKD *xd,
|
||||||
|
|
||||||
void vp9_build_intra_predictors_sbuv_s(MACROBLOCKD *xd,
|
void vp9_build_intra_predictors_sbuv_s(MACROBLOCKD *xd,
|
||||||
BLOCK_SIZE_TYPE bsize) {
|
BLOCK_SIZE_TYPE bsize) {
|
||||||
const int bwl = mi_width_log2(bsize), bw = MI_UV_SIZE << bwl;
|
const int bwl = b_width_log2(bsize), bw = 2 << bwl;
|
||||||
const int bhl = mi_height_log2(bsize), bh = MI_UV_SIZE << bhl;
|
const int bhl = b_height_log2(bsize), bh = 2 << bhl;
|
||||||
|
|
||||||
vp9_build_intra_predictors(xd->plane[1].dst.buf, xd->plane[1].dst.stride,
|
vp9_build_intra_predictors(xd->plane[1].dst.buf, xd->plane[1].dst.stride,
|
||||||
xd->plane[1].dst.buf, xd->plane[1].dst.stride,
|
xd->plane[1].dst.buf, xd->plane[1].dst.stride,
|
||||||
|
|
|
@ -1071,8 +1071,8 @@ static void encode_sb_row(VP9_COMP *cpi,
|
||||||
xd->b_index = k;
|
xd->b_index = k;
|
||||||
|
|
||||||
// try 8x8 coding
|
// try 8x8 coding
|
||||||
pick_sb_modes(cpi, mi_row + y_idx_m + (k & 1),
|
pick_sb_modes(cpi, mi_row + y_idx_m + (k >> 1),
|
||||||
mi_col + x_idx_m + (k >> 1),
|
mi_col + x_idx_m + (k & 1),
|
||||||
tp, &r, &d, BLOCK_SIZE_SB8X8,
|
tp, &r, &d, BLOCK_SIZE_SB8X8,
|
||||||
&x->sb8_context[xd->sb_index][xd->mb_index]
|
&x->sb8_context[xd->sb_index][xd->mb_index]
|
||||||
[xd->b_index]);
|
[xd->b_index]);
|
||||||
|
@ -1082,7 +1082,8 @@ static void encode_sb_row(VP9_COMP *cpi,
|
||||||
[xd->b_index],
|
[xd->b_index],
|
||||||
BLOCK_SIZE_SB8X8, 0);
|
BLOCK_SIZE_SB8X8, 0);
|
||||||
encode_superblock(cpi, tp,
|
encode_superblock(cpi, tp,
|
||||||
0, mi_row + y_idx_m, mi_col + x_idx_m,
|
0, mi_row + y_idx_m + (k >> 1),
|
||||||
|
mi_col + x_idx_m + (k & 1),
|
||||||
BLOCK_SIZE_SB8X8);
|
BLOCK_SIZE_SB8X8);
|
||||||
}
|
}
|
||||||
set_partition_seg_context(cpi, mi_row + y_idx_m, mi_col + x_idx_m);
|
set_partition_seg_context(cpi, mi_row + y_idx_m, mi_col + x_idx_m);
|
||||||
|
@ -2430,6 +2431,7 @@ static void encode_superblock(VP9_COMP *cpi, TOKENEXTRA **t,
|
||||||
vp9_subtract_sbuv(x, bsize);
|
vp9_subtract_sbuv(x, bsize);
|
||||||
vp9_transform_sbuv_4x4(x, bsize);
|
vp9_transform_sbuv_4x4(x, bsize);
|
||||||
vp9_quantize_sbuv_4x4(x, bsize);
|
vp9_quantize_sbuv_4x4(x, bsize);
|
||||||
|
if (x->optimize)
|
||||||
vp9_optimize_sbuv(cm, x, bsize);
|
vp9_optimize_sbuv(cm, x, bsize);
|
||||||
vp9_inverse_transform_sbuv_4x4(xd, bsize);
|
vp9_inverse_transform_sbuv_4x4(xd, bsize);
|
||||||
vp9_recon_sbuv(xd, bsize);
|
vp9_recon_sbuv(xd, bsize);
|
||||||
|
|
Загрузка…
Ссылка в новой задаче