PR #23023 opened by mkver
URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/23023
Patch URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/23023.patch


>From 1c93dddbf0f92bbfea95200dccae809d81004c61 Mon Sep 17 00:00:00 2001
From: Andreas Rheinhardt <[email protected]>
Date: Mon, 20 Oct 2025 19:17:43 +0200
Subject: [PATCH] avcodec/{vc1dsp,x86/vc1dsp_mmx}: Consistently use ptrdiff_t
 for stride

Signed-off-by: Andreas Rheinhardt <[email protected]>
---
 libavcodec/vc1dsp.c         | 4 ++--
 libavcodec/x86/vc1dsp_mmx.c | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/libavcodec/vc1dsp.c b/libavcodec/vc1dsp.c
index 864a6e5e7b..00fe64bced 100644
--- a/libavcodec/vc1dsp.c
+++ b/libavcodec/vc1dsp.c
@@ -547,7 +547,7 @@ static void vc1_inv_trans_4x4_c(uint8_t *dest, ptrdiff_t 
stride, int16_t *block)
 /* Filter in case of 2 filters */
 #define VC1_MSPEL_FILTER_16B(DIR, TYPE)                                       \
 static av_always_inline int vc1_mspel_ ## DIR ## _filter_16bits(const TYPE 
*src, \
-                                                                int stride,   \
+                                                                ptrdiff_t 
stride, \
                                                                 int mode)     \
 {                                                                             \
     switch(mode) {                                                            \
@@ -570,7 +570,7 @@ VC1_MSPEL_FILTER_16B(ver, uint8_t)
 VC1_MSPEL_FILTER_16B(hor, int16_t)
 
 /* Filter used to interpolate fractional pel values */
-static av_always_inline int vc1_mspel_filter(const uint8_t *src, int stride,
+static av_always_inline int vc1_mspel_filter(const uint8_t *src, ptrdiff_t 
stride,
                                              int mode, int r)
 {
     switch (mode) {
diff --git a/libavcodec/x86/vc1dsp_mmx.c b/libavcodec/x86/vc1dsp_mmx.c
index 3c771feb4b..dbc942f8df 100644
--- a/libavcodec/x86/vc1dsp_mmx.c
+++ b/libavcodec/x86/vc1dsp_mmx.c
@@ -336,7 +336,7 @@ typedef void (*vc1_mspel_mc_filter_8bits)(uint8_t *dst, 
const uint8_t *src, x86_
  * @param  rnd     Rounding bias.
  */
 #define VC1_MSPEL_MC(OP, INSTR)\
-static void OP ## vc1_mspel_mc(uint8_t *dst, const uint8_t *src, int stride,\
+static void OP ## vc1_mspel_mc(uint8_t *dst, const uint8_t *src, ptrdiff_t 
stride,\
                                int hmode, int vmode, int rnd)\
 {\
     static const vc1_mspel_mc_filter_ver_16bits vc1_put_shift_ver_16bits[] =\
-- 
2.52.0

_______________________________________________
ffmpeg-devel mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to