From 214b52df4341c610e0159618c08d96e823f26de8 Mon Sep 17 00:00:00 2001 From: Andreas Rheinhardt Date: Mon, 13 Oct 2025 12:20:32 +0200 Subject: [PATCH] avfilter/vf_noise: Avoid cast Signed-off-by: Andreas Rheinhardt --- libavfilter/vf_noise.c | 2 +- libavfilter/vf_noise.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/libavfilter/vf_noise.c b/libavfilter/vf_noise.c index 5b88b76e05..43e7ad6c45 100644 --- a/libavfilter/vf_noise.c +++ b/libavfilter/vf_noise.c @@ -213,7 +213,7 @@ static void noise(uint8_t *dst, const uint8_t *src, int shift = p->rand_shift[ix]; if (flags & NOISE_AVERAGED) { - n->line_noise_avg(dst + x, src + x, w, (const int8_t**)p->prev_shift[ix]); + n->line_noise_avg(dst + x, src + x, w, p->prev_shift[ix]); p->prev_shift[ix][shift % 3] = noise + shift; } else { n->line_noise(dst + x, src + x, noise, w, shift); diff --git a/libavfilter/vf_noise.h b/libavfilter/vf_noise.h index 62d7bee02c..081a0bbf77 100644 --- a/libavfilter/vf_noise.h +++ b/libavfilter/vf_noise.h @@ -40,7 +40,7 @@ typedef struct FilterParams { AVLFG lfg; int seed; int8_t *noise; - int8_t *prev_shift[MAX_RES][3]; + const int8_t *prev_shift[MAX_RES][3]; int rand_shift[MAX_RES]; int rand_shift_init; } FilterParams;