Commit 8d42fad9 authored by Jingning Han's avatar Jingning Han
Browse files

Move overlay frame speed feature setting out of mode search loop

Refactor overlay frame speed-up related function. Make it unified
with the ref_frame_skip_mask system and Move it out of the mode
search loop.

Change-Id: I0dde9baf44354f6ba00b4679cba02fa6a30c7316
parent f9f08797
...@@ -2677,6 +2677,14 @@ int64_t vp9_rd_pick_inter_mode_sb(VP9_COMP *cpi, MACROBLOCK *x, ...@@ -2677,6 +2677,14 @@ int64_t vp9_rd_pick_inter_mode_sb(VP9_COMP *cpi, MACROBLOCK *x,
} }
} }
if (cpi->rc.is_src_frame_alt_ref) {
if (cpi->sf.alt_ref_search_fp) {
mode_skip_mask[ALTREF_FRAME] = 0;
ref_frame_skip_mask[0] = ~(1 << ALTREF_FRAME);
ref_frame_skip_mask[1] = SECOND_REF_FRAME_MASK;
}
}
for (mode_index = 0; mode_index < MAX_MODES; ++mode_index) { for (mode_index = 0; mode_index < MAX_MODES; ++mode_index) {
int mode_excluded = 0; int mode_excluded = 0;
int64_t this_rd = INT64_MAX; int64_t this_rd = INT64_MAX;
...@@ -2721,15 +2729,6 @@ int64_t vp9_rd_pick_inter_mode_sb(VP9_COMP *cpi, MACROBLOCK *x, ...@@ -2721,15 +2729,6 @@ int64_t vp9_rd_pick_inter_mode_sb(VP9_COMP *cpi, MACROBLOCK *x,
} }
} }
if (cpi->rc.is_src_frame_alt_ref) {
if (cpi->sf.alt_ref_search_fp) {
mode_skip_mask[ALTREF_FRAME] = 0;
if (!(ref_frame == ALTREF_FRAME && second_ref_frame == NONE))
continue;
}
}
if (bsize > cpi->sf.max_intra_bsize) if (bsize > cpi->sf.max_intra_bsize)
if (ref_frame == INTRA_FRAME) if (ref_frame == INTRA_FRAME)
continue; continue;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment