removed the dependency cross key frame boundary
This allowed decoding from any key frame after skipping the frames prior. Change-Id: I096fccad5346d75ae50a017c94eb8d772a7e8b00
This commit is contained in:
parent
f6022327f1
commit
707e6c301e
@ -21,7 +21,7 @@
|
||||
|
||||
extern void vp8_init_scan_order_mask();
|
||||
|
||||
static void update_mode_info_border(VP8_COMMON *cpi, MODE_INFO *mi_base) {
|
||||
void update_mode_info_border(VP8_COMMON *cpi, MODE_INFO *mi_base) {
|
||||
int stride = cpi->mode_info_stride;
|
||||
int i;
|
||||
|
||||
@ -33,7 +33,7 @@ static void update_mode_info_border(VP8_COMMON *cpi, MODE_INFO *mi_base) {
|
||||
vpx_memset(&mi_base[i * stride], 0, sizeof(MODE_INFO));
|
||||
}
|
||||
}
|
||||
static void update_mode_info_in_image(VP8_COMMON *cpi, MODE_INFO *mi) {
|
||||
void update_mode_info_in_image(VP8_COMMON *cpi, MODE_INFO *mi) {
|
||||
int i, j;
|
||||
|
||||
// For each in image mode_info element set the in image flag to 1
|
||||
|
@ -825,6 +825,7 @@ static void init_frame(VP8D_COMP *pbi) {
|
||||
vp8_init_mv_probs(pc);
|
||||
|
||||
vp8_init_mbmode_probs(pc);
|
||||
vp8_default_bmode_probs(pc->fc.bmode_prob);
|
||||
|
||||
vp8_default_coef_probs(pc);
|
||||
vp8_kf_default_bmode_probs(pc->kf_bmode_prob);
|
||||
@ -858,6 +859,14 @@ static void init_frame(VP8D_COMP *pbi) {
|
||||
vpx_memcpy(pbi->common.fc.vp8_mode_contexts,
|
||||
pbi->common.fc.mode_context,
|
||||
sizeof(pbi->common.fc.mode_context));
|
||||
vpx_memset(pc->prev_mip, 0,
|
||||
(pc->mb_cols + 1) * (pc->mb_rows + 1)* sizeof(MODE_INFO));
|
||||
vpx_memset(pc->mip, 0,
|
||||
(pc->mb_cols + 1) * (pc->mb_rows + 1)* sizeof(MODE_INFO));
|
||||
|
||||
update_mode_info_border(pc, pc->mip);
|
||||
update_mode_info_in_image(pc, pc->mi);
|
||||
|
||||
} else {
|
||||
|
||||
if (!pc->use_bilinear_mc_filter)
|
||||
|
@ -267,10 +267,12 @@ void vp8_restore_coding_context(VP8_COMP *cpi) {
|
||||
|
||||
|
||||
void vp8_setup_key_frame(VP8_COMP *cpi) {
|
||||
VP8_COMMON *cm = &cpi->common;
|
||||
// Setup for Key frame:
|
||||
vp8_default_coef_probs(& cpi->common);
|
||||
vp8_kf_default_bmode_probs(cpi->common.kf_bmode_prob);
|
||||
vp8_init_mbmode_probs(& cpi->common);
|
||||
vp8_default_bmode_probs(cm->fc.bmode_prob);
|
||||
|
||||
vp8_init_mv_probs(& cpi->common);
|
||||
#if CONFIG_NEWMVENTROPY == 0
|
||||
@ -297,6 +299,15 @@ void vp8_setup_key_frame(VP8_COMP *cpi) {
|
||||
vpx_memcpy(&cpi->common.lfc, &cpi->common.fc, sizeof(cpi->common.fc));
|
||||
vpx_memcpy(&cpi->common.lfc_a, &cpi->common.fc, sizeof(cpi->common.fc));
|
||||
|
||||
vpx_memset(cm->prev_mip, 0,
|
||||
(cm->mb_cols + 1) * (cm->mb_rows + 1)* sizeof(MODE_INFO));
|
||||
vpx_memset(cm->mip, 0,
|
||||
(cm->mb_cols + 1) * (cm->mb_rows + 1)* sizeof(MODE_INFO));
|
||||
|
||||
update_mode_info_border(cm, cm->mip);
|
||||
update_mode_info_in_image(cm, cm->mi);
|
||||
|
||||
|
||||
}
|
||||
|
||||
void vp8_setup_inter_frame(VP8_COMP *cpi) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user