summaryrefslogtreecommitdiff
path: root/vp9
diff options
context:
space:
mode:
authorMarco Paniconi <marpan@google.com>2022-05-12 11:18:19 -0700
committerMarco Paniconi <marpan@google.com>2022-05-12 18:28:08 -0700
commita6bff83a603affa2799bbacedc24f9ca8632a5c6 (patch)
tree97d63b12b6a1b341c6ecc57ed5f7572d7ded24fc /vp9
parente8579cc3d4302214805bb28fbc27b771b1047325 (diff)
downloadlibvpx-a6bff83a603affa2799bbacedc24f9ca8632a5c6.tar
libvpx-a6bff83a603affa2799bbacedc24f9ca8632a5c6.tar.gz
libvpx-a6bff83a603affa2799bbacedc24f9ca8632a5c6.tar.bz2
libvpx-a6bff83a603affa2799bbacedc24f9ca8632a5c6.zip
vp9-rtc: Fix to interp_filter for segment skip
For segment skip feature: allow for setting the mi->interp_filter to BILINEAR, if cm->interp_filter is set BILIENAR. This can happen at speed 9 when the segment skip feature is used (e.g., active_maps) Without this fix the assert can be triggered with the active_map_test.cc for speed 9 included. Updated the test. Fixes the assert triggered in the issue: Bug: webm:1762 Change-Id: I462e0bdd966e4f3cb5b7bc746685916ac8808358
Diffstat (limited to 'vp9')
-rw-r--r--vp9/encoder/vp9_encodeframe.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/vp9/encoder/vp9_encodeframe.c b/vp9/encoder/vp9_encodeframe.c
index fc4089865..9da8f61e3 100644
--- a/vp9/encoder/vp9_encodeframe.c
+++ b/vp9/encoder/vp9_encodeframe.c
@@ -1905,13 +1905,17 @@ void vp9_setup_src_planes(MACROBLOCK *x, const YV12_BUFFER_CONFIG *src,
}
static void set_mode_info_seg_skip(MACROBLOCK *x, TX_MODE tx_mode,
+ INTERP_FILTER interp_filter,
RD_COST *rd_cost, BLOCK_SIZE bsize) {
MACROBLOCKD *const xd = &x->e_mbd;
MODE_INFO *const mi = xd->mi[0];
INTERP_FILTER filter_ref;
filter_ref = get_pred_context_switchable_interp(xd);
- if (filter_ref == SWITCHABLE_FILTERS) filter_ref = EIGHTTAP;
+ if (interp_filter == BILINEAR)
+ filter_ref = BILINEAR;
+ else if (filter_ref == SWITCHABLE_FILTERS)
+ filter_ref = EIGHTTAP;
mi->sb_type = bsize;
mi->mode = ZEROMV;
@@ -4682,7 +4686,7 @@ static void nonrd_pick_sb_modes(VP9_COMP *cpi, TileDataEnc *tile_data,
hybrid_search_svc_baseiskey(cpi, x, rd_cost, bsize, ctx, tile_data, mi_row,
mi_col);
else if (segfeature_active(&cm->seg, mi->segment_id, SEG_LVL_SKIP))
- set_mode_info_seg_skip(x, cm->tx_mode, rd_cost, bsize);
+ set_mode_info_seg_skip(x, cm->tx_mode, cm->interp_filter, rd_cost, bsize);
else if (bsize >= BLOCK_8X8) {
if (cpi->rc.hybrid_intra_scene_change)
hybrid_search_scene_change(cpi, x, rd_cost, bsize, ctx, tile_data, mi_row,