Commit 707d77fd28 for ffmpeg
commit 707d77fd2817948c7b30934d1de7f3eb4c2d7906
Author: hyena <25s103191@stu.hit.edu.cn>
Date: Fri Oct 30 04:59:26 2026 -0700
avcodec/vvc: fix argument order in weighted RPR callbacks
The DSP interface and mc_uni_scaled() pass height before denom, wx and
ox, but both weighted RPR callbacks declare height after them. Since
these parameters are all int, the mismatch is not diagnosed by the
compiler. In particular, a zero offset is read as a zero block height,
leaving the prediction block untouched.
Match both callback signatures to the DSP interface.
Signed-off-by: hyena <25s103191@stu.hit.edu.cn>
diff --git a/libavcodec/vvc/inter_template.c b/libavcodec/vvc/inter_template.c
index efa432d1fd..e06eab5ffa 100644
--- a/libavcodec/vvc/inter_template.c
+++ b/libavcodec/vvc/inter_template.c
@@ -166,16 +166,16 @@ static void av_always_inline FUNC(put_uni_w_scaled)(uint8_t *_dst, const ptrdiff
static void FUNC(put_uni_luma_w_scaled)(uint8_t *_dst, const ptrdiff_t _dst_stride,
const uint8_t *_src, ptrdiff_t _src_stride, const int src_height,
- const int x, const int y, const int dx, const int dy, const int denom, const int wx, const int ox,
- const int height, const int8_t *hf, const int8_t *vf, const int width)
+ const int x, const int y, const int dx, const int dy, const int height,
+ const int denom, const int wx, const int ox, const int8_t *hf, const int8_t *vf, const int width)
{
FUNC(put_uni_w_scaled)(_dst, _dst_stride, _src, _src_stride, src_height, x, y, dx, dy, denom, wx, ox, height, hf, vf, width, 0);
}
static void FUNC(put_uni_chroma_w_scaled)(uint8_t *_dst, const ptrdiff_t _dst_stride,
const uint8_t *_src, ptrdiff_t _src_stride, const int src_height,
- const int x, const int y, const int dx, const int dy, const int denom, const int wx, const int ox,
- const int height, const int8_t *hf, const int8_t *vf, const int width)
+ const int x, const int y, const int dx, const int dy, const int height,
+ const int denom, const int wx, const int ox, const int8_t *hf, const int8_t *vf, const int width)
{
FUNC(put_uni_w_scaled)(_dst, _dst_stride, _src, _src_stride, src_height, x, y, dx, dy, denom, wx, ox, height, hf, vf, width, 1);
}