}
}
-static int check_inside(VP9_COMMON *cm, int mi_row, int mi_col) {
- return mi_row >= 0 && mi_col >= 0 &&
- mi_row < cm->mi_rows && mi_col < cm->mi_cols;
+static int check_inside(const TileInfo *const tile, int mi_row, int mi_col) {
+ return mi_row >= tile->mi_row_start && mi_col >= tile->mi_col_start &&
+ mi_row < tile->mi_row_end && mi_col < tile->mi_col_end;
}
static int is_right_available(BLOCK_SIZE bsize, int mi_row, int mi_col) {
}
int vp9_construct_ref_inter_list(VP9_COMMON *cm, MACROBLOCKD *xd,
+ const TileInfo *const tile,
BLOCK_SIZE bsize, int mi_row, int mi_col,
MB_MODE_INFO *ref_list[18]) {
int bw = 4 << b_width_log2_lookup[bsize];
col_offset = col_offset_cand[i];
if ((col_offset < (bw / 8) ||
(col_offset == (bw / 8) && is_right_available(bsize, mi_row, mi_col)))
- && check_inside(cm, mi_row + row_offset, mi_col + col_offset)) {
+ && check_inside(tile, mi_row + row_offset, mi_col + col_offset)) {
mi_offset = row_offset * cm->mi_stride + col_offset;
ref_mbmi = &xd->mi[mi_offset].src_mi->mbmi;
if (is_inter_block(ref_mbmi)) {
#if CONFIG_COPY_MODE
int vp9_construct_ref_inter_list(VP9_COMMON *cm, MACROBLOCKD *xd,
+ const TileInfo *const tile,
BLOCK_SIZE bsize, int mi_row, int mi_col,
MB_MODE_INFO *ref_list[18]);
#endif // CONFIG_COPY_MODE
#if CONFIG_COPY_MODE
if (mbmi->sb_type >= BLOCK_8X8)
num_candidate = vp9_construct_ref_inter_list(
- cm, xd, mbmi->sb_type, mi_row, mi_col, inter_ref_list);
+ cm, xd, tile, mbmi->sb_type, mi_row, mi_col, inter_ref_list);
if (mbmi->sb_type >= BLOCK_8X8 && num_candidate > 0) {
int ctx = vp9_get_copy_mode_context(xd);
int is_copy = vp9_read(r, cm->fc.copy_noref_prob[ctx][mbmi->sb_type]);
&comp_mode_p);
#if CONFIG_COPY_MODE
inter_ref_count =
- vp9_construct_ref_inter_list(cm, xd, bsize, mi_row, mi_col, inter_ref_list);
+ vp9_construct_ref_inter_list(cm, xd, tile, bsize, mi_row, mi_col,
+ inter_ref_list);
mbmi->inter_ref_count = inter_ref_count;
#endif // CONFIG_COPY_MODE