experiment with CONTEXT conversion
This commit changed the ENTROPY_CONTEXT conversion between MBs that have different transform sizes. In additioin, this commit also did a number of cleanup/bug fix: 1. removed duplicate function vp9_fix_contexts() and changed to use vp8_reset_mb_token_contexts() for both encoder and decoder 2. fixed a bug in stuff_mb_16x16 where wrong context was used for the UV. 3. changed reset all context to 0 if a MB is skipped to simplify the logic. Change-Id: I7bc57a5fb6dbf1f85eac1543daaeb3a61633275c
This commit is contained in:
parent
fbf052df42
commit
ab480cede5
1
configure
vendored
1
configure
vendored
@ -249,6 +249,7 @@ EXPERIMENT_LIST="
|
|||||||
comp_interintra_pred
|
comp_interintra_pred
|
||||||
tx32x32
|
tx32x32
|
||||||
dwt32x32hybrid
|
dwt32x32hybrid
|
||||||
|
cnvcontext
|
||||||
"
|
"
|
||||||
CONFIG_LIST="
|
CONFIG_LIST="
|
||||||
external_build
|
external_build
|
||||||
|
@ -102,13 +102,11 @@ typedef enum
|
|||||||
TM_PRED, /* Truemotion prediction */
|
TM_PRED, /* Truemotion prediction */
|
||||||
I8X8_PRED, /* 8x8 based prediction, each 8x8 has its own prediction mode */
|
I8X8_PRED, /* 8x8 based prediction, each 8x8 has its own prediction mode */
|
||||||
B_PRED, /* block based prediction, each block has its own prediction mode */
|
B_PRED, /* block based prediction, each block has its own prediction mode */
|
||||||
|
|
||||||
NEARESTMV,
|
NEARESTMV,
|
||||||
NEARMV,
|
NEARMV,
|
||||||
ZEROMV,
|
ZEROMV,
|
||||||
NEWMV,
|
NEWMV,
|
||||||
SPLITMV,
|
SPLITMV,
|
||||||
|
|
||||||
MB_MODE_COUNT
|
MB_MODE_COUNT
|
||||||
} MB_PREDICTION_MODE;
|
} MB_PREDICTION_MODE;
|
||||||
|
|
||||||
|
@ -129,4 +129,10 @@ void vp9_coef_tree_initialize(void);
|
|||||||
|
|
||||||
void vp9_adapt_coef_probs(struct VP9Common *);
|
void vp9_adapt_coef_probs(struct VP9Common *);
|
||||||
|
|
||||||
|
static void vp9_reset_mb_tokens_context(MACROBLOCKD* const xd) {
|
||||||
|
/* Clear entropy contexts */
|
||||||
|
vpx_memset(xd->above_context, 0, sizeof(ENTROPY_CONTEXT_PLANES));
|
||||||
|
vpx_memset(xd->left_context, 0, sizeof(ENTROPY_CONTEXT_PLANES));
|
||||||
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -14,6 +14,7 @@
|
|||||||
#include "vp9/common/vp9_reconintra.h"
|
#include "vp9/common/vp9_reconintra.h"
|
||||||
#include "vp9/common/vp9_reconintra4x4.h"
|
#include "vp9/common/vp9_reconintra4x4.h"
|
||||||
#include "vp9/common/vp9_reconinter.h"
|
#include "vp9/common/vp9_reconinter.h"
|
||||||
|
#include "vp9/common/vp9_entropy.h"
|
||||||
#include "vp9/decoder/vp9_decodframe.h"
|
#include "vp9/decoder/vp9_decodframe.h"
|
||||||
#include "vp9/decoder/vp9_detokenize.h"
|
#include "vp9/decoder/vp9_detokenize.h"
|
||||||
#include "vp9/common/vp9_invtrans.h"
|
#include "vp9/common/vp9_invtrans.h"
|
||||||
@ -443,12 +444,12 @@ static void decode_4x4(VP9D_COMP *pbi, MACROBLOCKD *xd,
|
|||||||
vp9_dequant_idct_add(b->qcoeff, b->dequant, b->predictor,
|
vp9_dequant_idct_add(b->qcoeff, b->dequant, b->predictor,
|
||||||
*(b->base_dst) + b->dst, 16, b->dst_stride);
|
*(b->base_dst) + b->dst, 16, b->dst_stride);
|
||||||
}
|
}
|
||||||
xd->above_context->y2 = 1;
|
|
||||||
xd->left_context->y2 = 1;
|
|
||||||
}
|
}
|
||||||
if (!xd->mode_info_context->mbmi.mb_skip_coeff) {
|
if (!xd->mode_info_context->mbmi.mb_skip_coeff) {
|
||||||
vp9_decode_mb_tokens_4x4_uv(pbi, xd, bc);
|
vp9_decode_mb_tokens_4x4_uv(pbi, xd, bc);
|
||||||
}
|
}
|
||||||
|
xd->above_context->y2 = 0;
|
||||||
|
xd->left_context->y2 = 0;
|
||||||
vp9_build_intra_predictors_mbuv(xd);
|
vp9_build_intra_predictors_mbuv(xd);
|
||||||
pbi->idct_add_uv_block(xd->qcoeff + 16 * 16,
|
pbi->idct_add_uv_block(xd->qcoeff + 16 * 16,
|
||||||
xd->block[16].dequant,
|
xd->block[16].dequant,
|
||||||
|
@ -15,7 +15,6 @@
|
|||||||
#include "vpx_mem/vpx_mem.h"
|
#include "vpx_mem/vpx_mem.h"
|
||||||
#include "vpx_ports/mem.h"
|
#include "vpx_ports/mem.h"
|
||||||
#include "vp9/decoder/vp9_detokenize.h"
|
#include "vp9/decoder/vp9_detokenize.h"
|
||||||
|
|
||||||
#include "vp9/common/vp9_seg_common.h"
|
#include "vp9/common/vp9_seg_common.h"
|
||||||
|
|
||||||
#define EOB_CONTEXT_NODE 0
|
#define EOB_CONTEXT_NODE 0
|
||||||
@ -59,22 +58,6 @@ static const unsigned char cat6_prob[15] = {
|
|||||||
254, 254, 254, 252, 249, 243, 230, 196, 177, 153, 140, 133, 130, 129, 0
|
254, 254, 254, 252, 249, 243, 230, 196, 177, 153, 140, 133, 130, 129, 0
|
||||||
};
|
};
|
||||||
|
|
||||||
void vp9_reset_mb_tokens_context(MACROBLOCKD* const xd) {
|
|
||||||
/* Clear entropy contexts */
|
|
||||||
if ((xd->mode_info_context->mbmi.mode != B_PRED &&
|
|
||||||
xd->mode_info_context->mbmi.mode != I8X8_PRED &&
|
|
||||||
xd->mode_info_context->mbmi.mode != SPLITMV)
|
|
||||||
|| xd->mode_info_context->mbmi.txfm_size == TX_16X16) {
|
|
||||||
vpx_memset(xd->above_context, 0, sizeof(ENTROPY_CONTEXT_PLANES));
|
|
||||||
vpx_memset(xd->left_context, 0, sizeof(ENTROPY_CONTEXT_PLANES));
|
|
||||||
} else {
|
|
||||||
vpx_memset(xd->above_context, 0, sizeof(ENTROPY_CONTEXT_PLANES) - 1);
|
|
||||||
vpx_memset(xd->left_context, 0, sizeof(ENTROPY_CONTEXT_PLANES) - 1);
|
|
||||||
xd->above_context->y2 = 1;
|
|
||||||
xd->left_context->y2 = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
DECLARE_ALIGNED(16, extern const unsigned char, vp9_norm[256]);
|
DECLARE_ALIGNED(16, extern const unsigned char, vp9_norm[256]);
|
||||||
|
|
||||||
static int get_signed(BOOL_DECODER *br, int value_to_sign) {
|
static int get_signed(BOOL_DECODER *br, int value_to_sign) {
|
||||||
@ -321,15 +304,23 @@ static int vp9_decode_mb_tokens_16x16(VP9D_COMP* const pbi,
|
|||||||
unsigned short* const eobs = xd->eobs;
|
unsigned short* const eobs = xd->eobs;
|
||||||
const int segment_id = xd->mode_info_context->mbmi.segment_id;
|
const int segment_id = xd->mode_info_context->mbmi.segment_id;
|
||||||
int c, i, eobtotal = 0, seg_eob;
|
int c, i, eobtotal = 0, seg_eob;
|
||||||
|
|
||||||
// Luma block
|
// Luma block
|
||||||
eobs[0] = c = decode_coefs(pbi, xd, bc, A, L, PLANE_TYPE_Y_WITH_DC,
|
|
||||||
|
#if CONFIG_CNVCONTEXT
|
||||||
|
ENTROPY_CONTEXT above_ec = (A[0] + A[1] + A[2] + A[3]) != 0;
|
||||||
|
ENTROPY_CONTEXT left_ec = (L[0] + L[1] + L[2] + L[3]) != 0;
|
||||||
|
#else
|
||||||
|
ENTROPY_CONTEXT above_ec = A[0];
|
||||||
|
ENTROPY_CONTEXT left_ec = L[0];
|
||||||
|
#endif
|
||||||
|
eobs[0] = c = decode_coefs(pbi, xd, bc, &above_ec, &left_ec,
|
||||||
|
PLANE_TYPE_Y_WITH_DC,
|
||||||
get_tx_type(xd, &xd->block[0]),
|
get_tx_type(xd, &xd->block[0]),
|
||||||
get_eob(xd, segment_id, 256),
|
get_eob(xd, segment_id, 256),
|
||||||
xd->qcoeff, vp9_default_zig_zag1d_16x16,
|
xd->qcoeff, vp9_default_zig_zag1d_16x16,
|
||||||
TX_16X16, vp9_coef_bands_16x16);
|
TX_16X16, vp9_coef_bands_16x16);
|
||||||
A[1] = A[2] = A[3] = A[0];
|
A[1] = A[2] = A[3] = A[0] = above_ec;
|
||||||
L[1] = L[2] = L[3] = L[0];
|
L[1] = L[2] = L[3] = L[0] = left_ec;
|
||||||
eobtotal += c;
|
eobtotal += c;
|
||||||
|
|
||||||
// 8x8 chroma blocks
|
// 8x8 chroma blocks
|
||||||
@ -337,13 +328,21 @@ static int vp9_decode_mb_tokens_16x16(VP9D_COMP* const pbi,
|
|||||||
for (i = 16; i < 24; i += 4) {
|
for (i = 16; i < 24; i += 4) {
|
||||||
ENTROPY_CONTEXT* const a = A + vp9_block2above_8x8[i];
|
ENTROPY_CONTEXT* const a = A + vp9_block2above_8x8[i];
|
||||||
ENTROPY_CONTEXT* const l = L + vp9_block2left_8x8[i];
|
ENTROPY_CONTEXT* const l = L + vp9_block2left_8x8[i];
|
||||||
|
#if CONFIG_CNVCONTEXT
|
||||||
eobs[i] = c = decode_coefs(pbi, xd, bc, a, l, PLANE_TYPE_UV,
|
above_ec = (a[0] + a[1]) != 0;
|
||||||
|
left_ec = (l[0] + l[1]) != 0;
|
||||||
|
#else
|
||||||
|
above_ec = a[0];
|
||||||
|
left_ec = l[0];
|
||||||
|
#endif
|
||||||
|
eobs[i] = c = decode_coefs(pbi, xd, bc,
|
||||||
|
&above_ec, &left_ec,
|
||||||
|
PLANE_TYPE_UV,
|
||||||
DCT_DCT, seg_eob, xd->block[i].qcoeff,
|
DCT_DCT, seg_eob, xd->block[i].qcoeff,
|
||||||
vp9_default_zig_zag1d_8x8,
|
vp9_default_zig_zag1d_8x8,
|
||||||
TX_8X8, vp9_coef_bands_8x8);
|
TX_8X8, vp9_coef_bands_8x8);
|
||||||
a[1] = a[0];
|
a[1] = a[0] = above_ec;
|
||||||
l[1] = l[0];
|
l[1] = l[0] = left_ec;
|
||||||
eobtotal += c;
|
eobtotal += c;
|
||||||
}
|
}
|
||||||
A[8] = 0;
|
A[8] = 0;
|
||||||
@ -374,8 +373,8 @@ static int vp9_decode_mb_tokens_8x8(VP9D_COMP* const pbi,
|
|||||||
eobtotal += c - 4;
|
eobtotal += c - 4;
|
||||||
type = PLANE_TYPE_Y_NO_DC;
|
type = PLANE_TYPE_Y_NO_DC;
|
||||||
} else {
|
} else {
|
||||||
xd->above_context->y2 = 1;
|
xd->above_context->y2 = 0;
|
||||||
xd->left_context->y2 = 1;
|
xd->left_context->y2 = 0;
|
||||||
eobs[24] = 0;
|
eobs[24] = 0;
|
||||||
type = PLANE_TYPE_Y_WITH_DC;
|
type = PLANE_TYPE_Y_WITH_DC;
|
||||||
}
|
}
|
||||||
@ -385,15 +384,21 @@ static int vp9_decode_mb_tokens_8x8(VP9D_COMP* const pbi,
|
|||||||
for (i = 0; i < 16; i += 4) {
|
for (i = 0; i < 16; i += 4) {
|
||||||
ENTROPY_CONTEXT *const a = A + vp9_block2above_8x8[i];
|
ENTROPY_CONTEXT *const a = A + vp9_block2above_8x8[i];
|
||||||
ENTROPY_CONTEXT *const l = L + vp9_block2left_8x8[i];
|
ENTROPY_CONTEXT *const l = L + vp9_block2left_8x8[i];
|
||||||
|
#if CONFIG_CNVCONTEXT
|
||||||
eobs[i] = c = decode_coefs(pbi, xd, bc, a, l, type,
|
ENTROPY_CONTEXT above_ec = (a[0] + a[1]) != 0;
|
||||||
|
ENTROPY_CONTEXT left_ec = (l[0] + l[1]) != 0;
|
||||||
|
#else
|
||||||
|
ENTROPY_CONTEXT above_ec = a[0];
|
||||||
|
ENTROPY_CONTEXT left_ec = l[0];
|
||||||
|
#endif
|
||||||
|
eobs[i] = c = decode_coefs(pbi, xd, bc, &above_ec, &left_ec, type,
|
||||||
type == PLANE_TYPE_Y_WITH_DC ?
|
type == PLANE_TYPE_Y_WITH_DC ?
|
||||||
get_tx_type(xd, xd->block + i) : DCT_DCT,
|
get_tx_type(xd, xd->block + i) : DCT_DCT,
|
||||||
seg_eob, xd->block[i].qcoeff,
|
seg_eob, xd->block[i].qcoeff,
|
||||||
vp9_default_zig_zag1d_8x8,
|
vp9_default_zig_zag1d_8x8,
|
||||||
TX_8X8, vp9_coef_bands_8x8);
|
TX_8X8, vp9_coef_bands_8x8);
|
||||||
a[1] = a[0];
|
a[1] = a[0] = above_ec;
|
||||||
l[1] = l[0];
|
l[1] = l[0] = left_ec;
|
||||||
eobtotal += c;
|
eobtotal += c;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -415,13 +420,21 @@ static int vp9_decode_mb_tokens_8x8(VP9D_COMP* const pbi,
|
|||||||
for (i = 16; i < 24; i += 4) {
|
for (i = 16; i < 24; i += 4) {
|
||||||
ENTROPY_CONTEXT *const a = A + vp9_block2above_8x8[i];
|
ENTROPY_CONTEXT *const a = A + vp9_block2above_8x8[i];
|
||||||
ENTROPY_CONTEXT *const l = L + vp9_block2left_8x8[i];
|
ENTROPY_CONTEXT *const l = L + vp9_block2left_8x8[i];
|
||||||
|
#if CONFIG_CNVCONTEXT
|
||||||
eobs[i] = c = decode_coefs(pbi, xd, bc, a, l, PLANE_TYPE_UV,
|
ENTROPY_CONTEXT above_ec = (a[0] + a[1]) != 0;
|
||||||
|
ENTROPY_CONTEXT left_ec = (l[0] + l[1]) != 0;
|
||||||
|
#else
|
||||||
|
ENTROPY_CONTEXT above_ec = a[0];
|
||||||
|
ENTROPY_CONTEXT left_ec = l[0];
|
||||||
|
#endif
|
||||||
|
eobs[i] = c = decode_coefs(pbi, xd, bc,
|
||||||
|
&above_ec, &left_ec,
|
||||||
|
PLANE_TYPE_UV,
|
||||||
DCT_DCT, seg_eob, xd->block[i].qcoeff,
|
DCT_DCT, seg_eob, xd->block[i].qcoeff,
|
||||||
vp9_default_zig_zag1d_8x8,
|
vp9_default_zig_zag1d_8x8,
|
||||||
TX_8X8, vp9_coef_bands_8x8);
|
TX_8X8, vp9_coef_bands_8x8);
|
||||||
a[1] = a[0];
|
a[1] = a[0] = above_ec;
|
||||||
l[1] = l[0];
|
l[1] = l[0] = left_ec;
|
||||||
eobtotal += c;
|
eobtotal += c;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -517,8 +530,8 @@ static int vp9_decode_mb_tokens_4x4(VP9D_COMP* const dx,
|
|||||||
DCT_DCT, vp9_default_zig_zag1d) - 16;
|
DCT_DCT, vp9_default_zig_zag1d) - 16;
|
||||||
type = PLANE_TYPE_Y_NO_DC;
|
type = PLANE_TYPE_Y_NO_DC;
|
||||||
} else {
|
} else {
|
||||||
xd->above_context->y2 = 1;
|
xd->above_context->y2 = 0;
|
||||||
xd->left_context->y2 = 1;
|
xd->left_context->y2 = 0;
|
||||||
xd->eobs[24] = 0;
|
xd->eobs[24] = 0;
|
||||||
type = PLANE_TYPE_Y_WITH_DC;
|
type = PLANE_TYPE_Y_WITH_DC;
|
||||||
}
|
}
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
#include "vp9/common/vp9_common.h"
|
#include "vp9/common/vp9_common.h"
|
||||||
#include "vp9/encoder/vp9_onyx_int.h"
|
#include "vp9/encoder/vp9_onyx_int.h"
|
||||||
#include "vp9/common/vp9_extend.h"
|
#include "vp9/common/vp9_extend.h"
|
||||||
|
#include "vp9/common/vp9_entropy.h"
|
||||||
#include "vp9/common/vp9_entropymode.h"
|
#include "vp9/common/vp9_entropymode.h"
|
||||||
#include "vp9/common/vp9_quant_common.h"
|
#include "vp9/common/vp9_quant_common.h"
|
||||||
#include "vp9/encoder/vp9_segmentation.h"
|
#include "vp9/encoder/vp9_segmentation.h"
|
||||||
@ -2287,7 +2288,7 @@ static void encode_macroblock(VP9_COMP *cpi, MACROBLOCK *x,
|
|||||||
mbmi->mb_skip_coeff = 1;
|
mbmi->mb_skip_coeff = 1;
|
||||||
if (output_enabled)
|
if (output_enabled)
|
||||||
cpi->skip_true_count[mb_skip_context]++;
|
cpi->skip_true_count[mb_skip_context]++;
|
||||||
vp9_fix_contexts(xd);
|
vp9_reset_mb_tokens_context(xd);
|
||||||
} else {
|
} else {
|
||||||
vp9_stuff_mb(cpi, xd, t, !output_enabled);
|
vp9_stuff_mb(cpi, xd, t, !output_enabled);
|
||||||
mbmi->mb_skip_coeff = 0;
|
mbmi->mb_skip_coeff = 0;
|
||||||
@ -2525,7 +2526,7 @@ static void encode_superblock(VP9_COMP *cpi, MACROBLOCK *x,
|
|||||||
if (cpi->common.mb_no_coeff_skip) {
|
if (cpi->common.mb_no_coeff_skip) {
|
||||||
// TODO(rbultje) this should be done per-sb instead of per-mb?
|
// TODO(rbultje) this should be done per-sb instead of per-mb?
|
||||||
cpi->skip_true_count[mb_skip_context]++;
|
cpi->skip_true_count[mb_skip_context]++;
|
||||||
vp9_fix_contexts(xd);
|
vp9_reset_mb_tokens_context(xd);
|
||||||
} else {
|
} else {
|
||||||
vp9_stuff_mb(cpi, xd, t, 0);
|
vp9_stuff_mb(cpi, xd, t, 0);
|
||||||
// TODO(rbultje) this should be done per-sb instead of per-mb?
|
// TODO(rbultje) this should be done per-sb instead of per-mb?
|
||||||
|
@ -727,14 +727,21 @@ void vp9_optimize_mby_8x8(MACROBLOCK *x) {
|
|||||||
tl = (ENTROPY_CONTEXT *)&t_left;
|
tl = (ENTROPY_CONTEXT *)&t_left;
|
||||||
type = has_2nd_order ? PLANE_TYPE_Y_NO_DC : PLANE_TYPE_Y_WITH_DC;
|
type = has_2nd_order ? PLANE_TYPE_Y_NO_DC : PLANE_TYPE_Y_WITH_DC;
|
||||||
for (b = 0; b < 16; b += 4) {
|
for (b = 0; b < 16; b += 4) {
|
||||||
optimize_b(x, b, type,
|
ENTROPY_CONTEXT *const a = ta + vp9_block2above_8x8[b];
|
||||||
ta + vp9_block2above_8x8[b], tl + vp9_block2left_8x8[b],
|
ENTROPY_CONTEXT *const l = tl + vp9_block2left_8x8[b];
|
||||||
TX_8X8);
|
#if CONFIG_CNVCONTEXT
|
||||||
ta[vp9_block2above_8x8[b] + 1] = ta[vp9_block2above_8x8[b]];
|
ENTROPY_CONTEXT above_ec = (a[0] + a[1]) != 0;
|
||||||
tl[vp9_block2left_8x8[b] + 1] = tl[vp9_block2left_8x8[b]];
|
ENTROPY_CONTEXT left_ec = (l[0] + l[1]) != 0;
|
||||||
|
#else
|
||||||
|
ENTROPY_CONTEXT above_ec = a[0];
|
||||||
|
ENTROPY_CONTEXT left_ec = l[0];
|
||||||
|
#endif
|
||||||
|
optimize_b(x, b, type, &above_ec, &left_ec, TX_8X8);
|
||||||
|
a[1] = a[0] = above_ec;
|
||||||
|
l[1] = l[0] = left_ec;
|
||||||
}
|
}
|
||||||
|
|
||||||
// 8x8 always have 2nd roder haar block
|
// 8x8 always have 2nd order block
|
||||||
if (has_2nd_order) {
|
if (has_2nd_order) {
|
||||||
check_reset_8x8_2nd_coeffs(&x->e_mbd,
|
check_reset_8x8_2nd_coeffs(&x->e_mbd,
|
||||||
ta + vp9_block2above_8x8[24],
|
ta + vp9_block2above_8x8[24],
|
||||||
@ -744,25 +751,23 @@ void vp9_optimize_mby_8x8(MACROBLOCK *x) {
|
|||||||
|
|
||||||
void vp9_optimize_mbuv_8x8(MACROBLOCK *x) {
|
void vp9_optimize_mbuv_8x8(MACROBLOCK *x) {
|
||||||
int b;
|
int b;
|
||||||
ENTROPY_CONTEXT_PLANES t_above, t_left;
|
ENTROPY_CONTEXT *const ta = (ENTROPY_CONTEXT *)x->e_mbd.above_context;
|
||||||
ENTROPY_CONTEXT *ta;
|
ENTROPY_CONTEXT *const tl = (ENTROPY_CONTEXT *)x->e_mbd.left_context;
|
||||||
ENTROPY_CONTEXT *tl;
|
|
||||||
|
|
||||||
if (!x->e_mbd.above_context || !x->e_mbd.left_context)
|
if (!ta || !tl)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
vpx_memcpy(&t_above, x->e_mbd.above_context, sizeof(ENTROPY_CONTEXT_PLANES));
|
|
||||||
vpx_memcpy(&t_left, x->e_mbd.left_context, sizeof(ENTROPY_CONTEXT_PLANES));
|
|
||||||
|
|
||||||
ta = (ENTROPY_CONTEXT *)&t_above;
|
|
||||||
tl = (ENTROPY_CONTEXT *)&t_left;
|
|
||||||
|
|
||||||
for (b = 16; b < 24; b += 4) {
|
for (b = 16; b < 24; b += 4) {
|
||||||
optimize_b(x, b, PLANE_TYPE_UV,
|
ENTROPY_CONTEXT *const a = ta + vp9_block2above_8x8[b];
|
||||||
ta + vp9_block2above_8x8[b], tl + vp9_block2left_8x8[b],
|
ENTROPY_CONTEXT *const l = tl + vp9_block2left_8x8[b];
|
||||||
TX_8X8);
|
#if CONFIG_CNVCONTEXT
|
||||||
ta[vp9_block2above_8x8[b] + 1] = ta[vp9_block2above_8x8[b]];
|
ENTROPY_CONTEXT above_ec = (a[0] + a[1]) != 0;
|
||||||
tl[vp9_block2left_8x8[b] + 1] = tl[vp9_block2left_8x8[b]];
|
ENTROPY_CONTEXT left_ec = (l[0] + l[1]) != 0;
|
||||||
|
#else
|
||||||
|
ENTROPY_CONTEXT above_ec = a[0];
|
||||||
|
ENTROPY_CONTEXT left_ec = l[0];
|
||||||
|
#endif
|
||||||
|
optimize_b(x, b, PLANE_TYPE_UV, &above_ec, &left_ec, TX_8X8);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -772,18 +777,21 @@ static void optimize_mb_8x8(MACROBLOCK *x) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void vp9_optimize_mby_16x16(MACROBLOCK *x) {
|
void vp9_optimize_mby_16x16(MACROBLOCK *x) {
|
||||||
ENTROPY_CONTEXT_PLANES t_above, t_left;
|
ENTROPY_CONTEXT_PLANES *const t_above = x->e_mbd.above_context;
|
||||||
ENTROPY_CONTEXT *ta, *tl;
|
ENTROPY_CONTEXT_PLANES *const t_left = x->e_mbd.left_context;
|
||||||
|
ENTROPY_CONTEXT ta, tl;
|
||||||
|
|
||||||
if (!x->e_mbd.above_context || !x->e_mbd.left_context)
|
if (!t_above || !t_left)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
vpx_memcpy(&t_above, x->e_mbd.above_context, sizeof(ENTROPY_CONTEXT_PLANES));
|
#if CONFIG_CNVCONTEXT
|
||||||
vpx_memcpy(&t_left, x->e_mbd.left_context, sizeof(ENTROPY_CONTEXT_PLANES));
|
ta = (t_above->y1[0] + t_above->y1[1] + t_above->y1[2] + t_above->y1[3]) != 0;
|
||||||
|
tl = (t_left->y1[0] + t_left->y1[1] + t_left->y1[2] + t_left->y1[3]) != 0;
|
||||||
ta = (ENTROPY_CONTEXT *)&t_above;
|
#else
|
||||||
tl = (ENTROPY_CONTEXT *)&t_left;
|
ta = t_above->y1[0];
|
||||||
optimize_b(x, 0, PLANE_TYPE_Y_WITH_DC, ta, tl, TX_16X16);
|
tl = t_left->y1[0];
|
||||||
|
#endif
|
||||||
|
optimize_b(x, 0, PLANE_TYPE_Y_WITH_DC, &ta, &tl, TX_16X16);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void optimize_mb_16x16(MACROBLOCK *x) {
|
static void optimize_mb_16x16(MACROBLOCK *x) {
|
||||||
|
@ -423,7 +423,7 @@ void vp9_tokenize_mb(VP9_COMP *cpi,
|
|||||||
if (!cpi->common.mb_no_coeff_skip) {
|
if (!cpi->common.mb_no_coeff_skip) {
|
||||||
vp9_stuff_mb(cpi, xd, t, dry_run);
|
vp9_stuff_mb(cpi, xd, t, dry_run);
|
||||||
} else {
|
} else {
|
||||||
vp9_fix_contexts(xd);
|
vp9_reset_mb_tokens_context(xd);
|
||||||
}
|
}
|
||||||
if (dry_run)
|
if (dry_run)
|
||||||
*t = t_backup;
|
*t = t_backup;
|
||||||
@ -434,45 +434,60 @@ void vp9_tokenize_mb(VP9_COMP *cpi,
|
|||||||
cpi->skip_false_count[mb_skip_context] += skip_inc;
|
cpi->skip_false_count[mb_skip_context] += skip_inc;
|
||||||
|
|
||||||
if (has_2nd_order) {
|
if (has_2nd_order) {
|
||||||
if (tx_size == TX_8X8) {
|
tokenize_b(cpi, xd, xd->block + 24, t, PLANE_TYPE_Y2,
|
||||||
tokenize_b(cpi, xd, xd->block + 24, t, PLANE_TYPE_Y2,
|
A + vp9_block2above_8x8[24], L + vp9_block2left_8x8[24],
|
||||||
A + vp9_block2above_8x8[24], L + vp9_block2left_8x8[24],
|
tx_size, dry_run);
|
||||||
TX_8X8, dry_run);
|
|
||||||
} else {
|
|
||||||
tokenize_b(cpi, xd, xd->block + 24, t, PLANE_TYPE_Y2,
|
|
||||||
A + vp9_block2above[24], L + vp9_block2left[24],
|
|
||||||
TX_4X4, dry_run);
|
|
||||||
}
|
|
||||||
|
|
||||||
plane_type = PLANE_TYPE_Y_NO_DC;
|
plane_type = PLANE_TYPE_Y_NO_DC;
|
||||||
} else {
|
} else {
|
||||||
xd->above_context->y2 = 1;
|
xd->above_context->y2 = 0;
|
||||||
xd->left_context->y2 = 1;
|
xd->left_context->y2 = 0;
|
||||||
plane_type = PLANE_TYPE_Y_WITH_DC;
|
plane_type = PLANE_TYPE_Y_WITH_DC;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (tx_size == TX_16X16) {
|
if (tx_size == TX_16X16) {
|
||||||
|
#if CONFIG_CNVCONTEXT
|
||||||
|
ENTROPY_CONTEXT above_ec = (A[0] + A[1] + A[2] + A[3]) != 0;
|
||||||
|
ENTROPY_CONTEXT left_ec = (L[0] + L[1] + L[2] + L[3]) != 0;
|
||||||
|
#else
|
||||||
|
ENTROPY_CONTEXT above_ec = A[0];
|
||||||
|
ENTROPY_CONTEXT left_ec = L[0];
|
||||||
|
#endif
|
||||||
tokenize_b(cpi, xd, xd->block, t, PLANE_TYPE_Y_WITH_DC,
|
tokenize_b(cpi, xd, xd->block, t, PLANE_TYPE_Y_WITH_DC,
|
||||||
A, L, TX_16X16, dry_run);
|
&above_ec, &left_ec, TX_16X16, dry_run);
|
||||||
A[1] = A[2] = A[3] = A[0];
|
A[1] = A[2] = A[3] = A[0] = above_ec;
|
||||||
L[1] = L[2] = L[3] = L[0];
|
L[1] = L[2] = L[3] = L[0] = left_ec;
|
||||||
|
|
||||||
for (b = 16; b < 24; b += 4) {
|
for (b = 16; b < 24; b += 4) {
|
||||||
|
ENTROPY_CONTEXT *const a = A + vp9_block2above_8x8[b];
|
||||||
|
ENTROPY_CONTEXT *const l = L + vp9_block2left_8x8[b];
|
||||||
|
#if CONFIG_CNVCONTEXT
|
||||||
|
above_ec = (a[0] + a[1]) != 0;
|
||||||
|
left_ec = (l[0] + l[1]) != 0;
|
||||||
|
#else
|
||||||
|
above_ec = a[0];
|
||||||
|
left_ec = l[0];
|
||||||
|
#endif
|
||||||
tokenize_b(cpi, xd, xd->block + b, t, PLANE_TYPE_UV,
|
tokenize_b(cpi, xd, xd->block + b, t, PLANE_TYPE_UV,
|
||||||
A + vp9_block2above_8x8[b], L + vp9_block2left_8x8[b],
|
&above_ec, &left_ec, TX_8X8, dry_run);
|
||||||
TX_8X8, dry_run);
|
a[1] = a[0] = above_ec;
|
||||||
A[vp9_block2above_8x8[b] + 1] = A[vp9_block2above_8x8[b]];
|
l[1] = l[0] = left_ec;
|
||||||
L[vp9_block2left_8x8[b] + 1] = L[vp9_block2left_8x8[b]];
|
|
||||||
}
|
}
|
||||||
A[8] = 0;
|
A[8] = 0;
|
||||||
L[8] = 0;
|
L[8] = 0;
|
||||||
} else if (tx_size == TX_8X8) {
|
} else if (tx_size == TX_8X8) {
|
||||||
for (b = 0; b < 16; b += 4) {
|
for (b = 0; b < 16; b += 4) {
|
||||||
|
ENTROPY_CONTEXT *const a = A + vp9_block2above_8x8[b];
|
||||||
|
ENTROPY_CONTEXT *const l = L + vp9_block2left_8x8[b];
|
||||||
|
#if CONFIG_CNVCONTEXT
|
||||||
|
ENTROPY_CONTEXT above_ec = (a[0] + a[1]) != 0;
|
||||||
|
ENTROPY_CONTEXT left_ec = (l[0] + l[1]) != 0;
|
||||||
|
#else
|
||||||
|
ENTROPY_CONTEXT above_ec = a[0];
|
||||||
|
ENTROPY_CONTEXT left_ec = l[0];
|
||||||
|
#endif
|
||||||
tokenize_b(cpi, xd, xd->block + b, t, plane_type,
|
tokenize_b(cpi, xd, xd->block + b, t, plane_type,
|
||||||
A + vp9_block2above_8x8[b], L + vp9_block2left_8x8[b],
|
&above_ec, &left_ec, TX_8X8, dry_run);
|
||||||
TX_8X8, dry_run);
|
a[1] = a[0] = above_ec;
|
||||||
A[vp9_block2above_8x8[b] + 1] = A[vp9_block2above_8x8[b]];
|
l[1] = l[0] = left_ec;
|
||||||
L[vp9_block2left_8x8[b] + 1] = L[vp9_block2left_8x8[b]];
|
|
||||||
}
|
}
|
||||||
if (xd->mode_info_context->mbmi.mode == I8X8_PRED ||
|
if (xd->mode_info_context->mbmi.mode == I8X8_PRED ||
|
||||||
xd->mode_info_context->mbmi.mode == SPLITMV) {
|
xd->mode_info_context->mbmi.mode == SPLITMV) {
|
||||||
@ -483,11 +498,19 @@ void vp9_tokenize_mb(VP9_COMP *cpi,
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
for (b = 16; b < 24; b += 4) {
|
for (b = 16; b < 24; b += 4) {
|
||||||
|
ENTROPY_CONTEXT *const a = A + vp9_block2above_8x8[b];
|
||||||
|
ENTROPY_CONTEXT *const l = L + vp9_block2left_8x8[b];
|
||||||
|
#if CONFIG_CNVCONTEXT
|
||||||
|
ENTROPY_CONTEXT above_ec = (a[0] + a[1]) != 0;
|
||||||
|
ENTROPY_CONTEXT left_ec = (l[0] + l[1]) != 0;
|
||||||
|
#else
|
||||||
|
ENTROPY_CONTEXT above_ec = a[0];
|
||||||
|
ENTROPY_CONTEXT left_ec = l[0];
|
||||||
|
#endif
|
||||||
tokenize_b(cpi, xd, xd->block + b, t, PLANE_TYPE_UV,
|
tokenize_b(cpi, xd, xd->block + b, t, PLANE_TYPE_UV,
|
||||||
A + vp9_block2above_8x8[b], L + vp9_block2left_8x8[b],
|
&above_ec, &left_ec, TX_8X8, dry_run);
|
||||||
TX_8X8, dry_run);
|
a[1] = a[0] = above_ec;
|
||||||
A[vp9_block2above_8x8[b] + 1] = A[vp9_block2above_8x8[b]];
|
l[1] = l[0] = left_ec;
|
||||||
L[vp9_block2left_8x8[b] + 1] = L[vp9_block2left_8x8[b]];
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
@ -794,66 +817,97 @@ static void stuff_mb_8x8(VP9_COMP *cpi, MACROBLOCKD *xd,
|
|||||||
TX_8X8, dry_run);
|
TX_8X8, dry_run);
|
||||||
plane_type = PLANE_TYPE_Y_NO_DC;
|
plane_type = PLANE_TYPE_Y_NO_DC;
|
||||||
} else {
|
} else {
|
||||||
xd->above_context->y2 = 1;
|
#if CONFIG_CNVCONTEXT
|
||||||
xd->left_context->y2 = 1;
|
xd->above_context->y2 = 0;
|
||||||
|
xd->left_context->y2 = 0;
|
||||||
|
#endif
|
||||||
plane_type = PLANE_TYPE_Y_WITH_DC;
|
plane_type = PLANE_TYPE_Y_WITH_DC;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (b = 0; b < 16; b += 4) {
|
for (b = 0; b < 16; b += 4) {
|
||||||
stuff_b(cpi, xd, xd->block + b, t, plane_type, A + vp9_block2above_8x8[b],
|
ENTROPY_CONTEXT *const a = A + vp9_block2above_8x8[b];
|
||||||
L + vp9_block2left_8x8[b], TX_8X8, dry_run);
|
ENTROPY_CONTEXT *const l = L + vp9_block2left_8x8[b];
|
||||||
A[vp9_block2above_8x8[b] + 1] = A[vp9_block2above_8x8[b]];
|
#if CONFIG_CNVCONTEXT
|
||||||
L[vp9_block2left_8x8[b] + 1] = L[vp9_block2left_8x8[b]];
|
ENTROPY_CONTEXT above_ec = (a[0] + a[1]) != 0;
|
||||||
|
ENTROPY_CONTEXT left_ec = (l[0] + l[1]) != 0;
|
||||||
|
#else
|
||||||
|
ENTROPY_CONTEXT above_ec = a[0];
|
||||||
|
ENTROPY_CONTEXT left_ec = l[0];
|
||||||
|
#endif
|
||||||
|
stuff_b(cpi, xd, xd->block + b, t, plane_type,
|
||||||
|
&above_ec, &left_ec, TX_8X8, dry_run);
|
||||||
|
a[1] = a[0] = above_ec;
|
||||||
|
l[1] = l[0] = left_ec;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (b = 16; b < 24; b += 4) {
|
for (b = 16; b < 24; b += 4) {
|
||||||
|
ENTROPY_CONTEXT *const a = A + vp9_block2above_8x8[b];
|
||||||
|
ENTROPY_CONTEXT *const l = L + vp9_block2left_8x8[b];
|
||||||
|
#if CONFIG_CNVCONTEXT
|
||||||
|
ENTROPY_CONTEXT above_ec = (a[0] + a[1]) != 0;
|
||||||
|
ENTROPY_CONTEXT left_ec = (l[0] + l[1]) != 0;
|
||||||
|
#else
|
||||||
|
ENTROPY_CONTEXT above_ec = a[0];
|
||||||
|
ENTROPY_CONTEXT left_ec = l[0];
|
||||||
|
#endif
|
||||||
stuff_b(cpi, xd, xd->block + b, t, PLANE_TYPE_UV,
|
stuff_b(cpi, xd, xd->block + b, t, PLANE_TYPE_UV,
|
||||||
A + vp9_block2above_8x8[b], L + vp9_block2left_8x8[b],
|
&above_ec, &left_ec, TX_8X8, dry_run);
|
||||||
TX_8X8, dry_run);
|
a[1] = a[0] = above_ec;
|
||||||
A[vp9_block2above_8x8[b] + 1] = A[vp9_block2above_8x8[b]];
|
l[1] = l[0] = left_ec;
|
||||||
L[vp9_block2left_8x8[b] + 1] = L[vp9_block2left_8x8[b]];
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void stuff_mb_16x16(VP9_COMP *cpi, MACROBLOCKD *xd,
|
static void stuff_mb_16x16(VP9_COMP *cpi, MACROBLOCKD *xd,
|
||||||
TOKENEXTRA **t, int dry_run) {
|
TOKENEXTRA **t, int dry_run) {
|
||||||
ENTROPY_CONTEXT * A = (ENTROPY_CONTEXT *)xd->above_context;
|
ENTROPY_CONTEXT *const A = (ENTROPY_CONTEXT *)xd->above_context;
|
||||||
ENTROPY_CONTEXT * L = (ENTROPY_CONTEXT *)xd->left_context;
|
ENTROPY_CONTEXT *const L = (ENTROPY_CONTEXT *)xd->left_context;
|
||||||
int b;
|
int b;
|
||||||
|
#if CONFIG_CNVCONTEXT
|
||||||
|
ENTROPY_CONTEXT above_ec = (A[0] + A[1] + A[2] + A[3]) != 0;
|
||||||
|
ENTROPY_CONTEXT left_ec = (L[0] + L[1] + L[2] + L[3]) != 0;
|
||||||
|
#else
|
||||||
|
ENTROPY_CONTEXT above_ec = A[0];
|
||||||
|
ENTROPY_CONTEXT left_ec = L[0];
|
||||||
|
#endif
|
||||||
|
stuff_b(cpi, xd, xd->block, t, PLANE_TYPE_Y_WITH_DC,
|
||||||
|
&above_ec, &left_ec, TX_16X16, dry_run);
|
||||||
|
A[1] = A[2] = A[3] = A[0] = above_ec;
|
||||||
|
L[1] = L[2] = L[3] = L[0] = left_ec;
|
||||||
|
|
||||||
stuff_b(cpi, xd, xd->block, t, PLANE_TYPE_Y_WITH_DC, A, L, TX_16X16, dry_run);
|
|
||||||
A[1] = A[2] = A[3] = A[0];
|
|
||||||
L[1] = L[2] = L[3] = L[0];
|
|
||||||
for (b = 16; b < 24; b += 4) {
|
for (b = 16; b < 24; b += 4) {
|
||||||
|
ENTROPY_CONTEXT *const a = A + vp9_block2above_8x8[b];
|
||||||
|
ENTROPY_CONTEXT *const l = L + vp9_block2left_8x8[b];
|
||||||
|
#if CONFIG_CNVCONTEXT
|
||||||
|
above_ec = (a[0] + a[1]) != 0;
|
||||||
|
left_ec = (l[0] + l[1]) != 0;
|
||||||
|
#else
|
||||||
|
above_ec = a[0];
|
||||||
|
left_ec = l[0];
|
||||||
|
#endif
|
||||||
stuff_b(cpi, xd, xd->block + b, t, PLANE_TYPE_UV,
|
stuff_b(cpi, xd, xd->block + b, t, PLANE_TYPE_UV,
|
||||||
A + vp9_block2above_8x8[b],
|
&above_ec, &left_ec, TX_8X8, dry_run);
|
||||||
L + vp9_block2above_8x8[b], TX_8X8, dry_run);
|
a[1] = a[0] = above_ec;
|
||||||
A[vp9_block2above_8x8[b] + 1] = A[vp9_block2above_8x8[b]];
|
l[1] = l[0] = left_ec;
|
||||||
L[vp9_block2left_8x8[b] + 1] = L[vp9_block2left_8x8[b]];
|
|
||||||
}
|
}
|
||||||
vpx_memset(&A[8], 0, sizeof(A[8]));
|
A[8] = 0;
|
||||||
vpx_memset(&L[8], 0, sizeof(L[8]));
|
L[8] = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void stuff_mb_4x4(VP9_COMP *cpi, MACROBLOCKD *xd,
|
static void stuff_mb_4x4(VP9_COMP *cpi, MACROBLOCKD *xd,
|
||||||
TOKENEXTRA **t, int dry_run) {
|
TOKENEXTRA **t, int dry_run) {
|
||||||
ENTROPY_CONTEXT *A = (ENTROPY_CONTEXT *)xd->above_context;
|
ENTROPY_CONTEXT *const A = (ENTROPY_CONTEXT *)xd->above_context;
|
||||||
ENTROPY_CONTEXT *L = (ENTROPY_CONTEXT *)xd->left_context;
|
ENTROPY_CONTEXT *const L = (ENTROPY_CONTEXT *)xd->left_context;
|
||||||
int b;
|
int b;
|
||||||
PLANE_TYPE plane_type;
|
PLANE_TYPE plane_type;
|
||||||
int has_2nd_order = (xd->mode_info_context->mbmi.mode != B_PRED &&
|
int has_2nd_order = get_2nd_order_usage(xd);
|
||||||
xd->mode_info_context->mbmi.mode != I8X8_PRED &&
|
|
||||||
xd->mode_info_context->mbmi.mode != SPLITMV);
|
|
||||||
if (has_2nd_order && get_tx_type(xd, &xd->block[0]) != DCT_DCT)
|
|
||||||
has_2nd_order = 0;
|
|
||||||
|
|
||||||
if (has_2nd_order) {
|
if (has_2nd_order) {
|
||||||
stuff_b(cpi, xd, xd->block + 24, t, PLANE_TYPE_Y2, A + vp9_block2above[24],
|
stuff_b(cpi, xd, xd->block + 24, t, PLANE_TYPE_Y2, A + vp9_block2above[24],
|
||||||
L + vp9_block2left[24], TX_4X4, dry_run);
|
L + vp9_block2left[24], TX_4X4, dry_run);
|
||||||
plane_type = PLANE_TYPE_Y_NO_DC;
|
plane_type = PLANE_TYPE_Y_NO_DC;
|
||||||
} else {
|
} else {
|
||||||
xd->above_context->y2 = 1;
|
xd->above_context->y2 = 0;
|
||||||
xd->left_context->y2 = 1;
|
xd->left_context->y2 = 0;
|
||||||
plane_type = PLANE_TYPE_Y_WITH_DC;
|
plane_type = PLANE_TYPE_Y_WITH_DC;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -880,22 +934,30 @@ static void stuff_mb_8x8_4x4uv(VP9_COMP *cpi, MACROBLOCKD *xd,
|
|||||||
TX_8X8, dry_run);
|
TX_8X8, dry_run);
|
||||||
plane_type = PLANE_TYPE_Y_NO_DC;
|
plane_type = PLANE_TYPE_Y_NO_DC;
|
||||||
} else {
|
} else {
|
||||||
|
xd->above_context->y2 = 0;
|
||||||
|
xd->left_context->y2 = 0;
|
||||||
plane_type = PLANE_TYPE_Y_WITH_DC;
|
plane_type = PLANE_TYPE_Y_WITH_DC;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (b = 0; b < 16; b += 4) {
|
for (b = 0; b < 16; b += 4) {
|
||||||
|
ENTROPY_CONTEXT *const a = A + vp9_block2above_8x8[b];
|
||||||
|
ENTROPY_CONTEXT *const l = L + vp9_block2left_8x8[b];
|
||||||
|
#if CONFIG_CNVCONTEXT
|
||||||
|
ENTROPY_CONTEXT above_ec = (a[0] + a[1]) != 0;
|
||||||
|
ENTROPY_CONTEXT left_ec = (l[0] + l[1]) != 0;
|
||||||
|
#else
|
||||||
|
ENTROPY_CONTEXT above_ec = a[0];
|
||||||
|
ENTROPY_CONTEXT left_ec = l[0];
|
||||||
|
#endif
|
||||||
stuff_b(cpi, xd, xd->block + b, t, plane_type,
|
stuff_b(cpi, xd, xd->block + b, t, plane_type,
|
||||||
A + vp9_block2above_8x8[b], L + vp9_block2left_8x8[b],
|
&above_ec, &left_ec, TX_8X8, dry_run);
|
||||||
TX_8X8, dry_run);
|
a[1] = a[0] = above_ec;
|
||||||
A[vp9_block2above_8x8[b] + 1] = A[vp9_block2above_8x8[b]];
|
l[1] = l[0] = left_ec;
|
||||||
L[vp9_block2left_8x8[b] + 1] = L[vp9_block2left_8x8[b]];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
for (b = 16; b < 24; b++)
|
for (b = 16; b < 24; b++)
|
||||||
stuff_b(cpi, xd, xd->block + b, t, PLANE_TYPE_UV, A + vp9_block2above[b],
|
stuff_b(cpi, xd, xd->block + b, t, PLANE_TYPE_UV, A + vp9_block2above[b],
|
||||||
L + vp9_block2left[b], TX_4X4, dry_run);
|
L + vp9_block2left[b], TX_4X4, dry_run);
|
||||||
xd->above_context->y2 = 1;
|
|
||||||
xd->left_context->y2 = 1;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void vp9_stuff_mb(VP9_COMP *cpi, MACROBLOCKD *xd, TOKENEXTRA **t, int dry_run) {
|
void vp9_stuff_mb(VP9_COMP *cpi, MACROBLOCKD *xd, TOKENEXTRA **t, int dry_run) {
|
||||||
|
@ -56,11 +56,9 @@ extern void vp9_stuff_sb(struct VP9_COMP *cpi, MACROBLOCKD *xd,
|
|||||||
TOKENEXTRA **t, int dry_run);
|
TOKENEXTRA **t, int dry_run);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
extern void vp9_fix_contexts(MACROBLOCKD *xd);
|
|
||||||
#if CONFIG_SUPERBLOCKS && CONFIG_TX32X32
|
#if CONFIG_SUPERBLOCKS && CONFIG_TX32X32
|
||||||
extern void vp9_fix_contexts_sb(MACROBLOCKD *xd);
|
extern void vp9_fix_contexts_sb(MACROBLOCKD *xd);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef ENTROPY_STATS
|
#ifdef ENTROPY_STATS
|
||||||
void init_context_counters();
|
void init_context_counters();
|
||||||
void print_context_counters();
|
void print_context_counters();
|
||||||
|
Loading…
Reference in New Issue
Block a user