avcodec/vvc/inter: Remove always-false/true checks

derive_weight() is only called when pred_flag is PF_BI,
which only happens in B slices.

Reviewed-by: Frank Plowman <post@frankplowman.com>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
Andreas Rheinhardt
2026-02-20 19:49:38 +01:00
parent cff9f29d5b
commit 6777d5cd48

View File

@@ -224,8 +224,8 @@ static int derive_weight(int *denom, int *w0, int *w1, int *o0, int *o1,
const VVCPPS *pps = fc->ps.pps;
const VVCSH *sh = &lc->sc->sh;
const int bcw_idx = mvf->bcw_idx;
const int weight_flag = (IS_P(sh->r) && pps->r->pps_weighted_pred_flag) ||
(IS_B(sh->r) && pps->r->pps_weighted_bipred_flag && !dmvr_flag);
av_assert2(IS_B(sh->r));
const int weight_flag = pps->r->pps_weighted_bipred_flag && !dmvr_flag;
if ((!weight_flag && !bcw_idx) || (bcw_idx && lc->cu->ciip_flag))
return 0;