From 7399d9f374db17942fad40839b7c366236c63014 Mon Sep 17 00:00:00 2001 From: Frank Plowman Date: Thu, 28 Nov 2024 22:17:24 +0000 Subject: [PATCH] lavc/vvc: Don't check motion estimation region for IBC The final parameter of check_available determines whether the motion estimation region constraints imposed in section 8.5.2.3 of H.266 (V3) on MVP candidates apply to the current candidate or not. In the case of IBC spatial merge candidates they do not, as their availability is dependent only on the criteria described in sections 8.6.2.3 and 6.4.4, which do not include this constraint on the motion estimation region. Signed-off-by: Frank Plowman --- libavcodec/vvc/mvs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavcodec/vvc/mvs.c b/libavcodec/vvc/mvs.c index 86ad310035..566df158a8 100644 --- a/libavcodec/vvc/mvs.c +++ b/libavcodec/vvc/mvs.c @@ -1627,12 +1627,12 @@ static int ibc_spatial_candidates(const VVCLocalContext *lc, const int merge_idx init_neighbour_context(&nctx, lc); - if (check_available(a1, lc, 1)) { + if (check_available(a1, lc, 0)) { cand_list[num_cands++] = TAB_MVF(a1->x, a1->y).mv[L0]; if (num_cands > merge_idx) return 1; } - if (check_available(b1, lc, 1)) { + if (check_available(b1, lc, 0)) { const MvField *mvf = &TAB_MVF(b1->x, b1->y); if (!num_cands || !IS_SAME_MV(&cand_list[0], mvf->mv)) { cand_list[num_cands++] = mvf->mv[L0];