From 7b8d5b7dc311328a3980548554020114b781f8ad Mon Sep 17 00:00:00 2001 From: Sylvain Becker Date: Wed, 23 Dec 2020 22:02:28 +0100 Subject: [PATCH] SDL_SoftStretchLinear: fix implicit conversion (bug 5313) --- src/video/SDL_stretch.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/video/SDL_stretch.c b/src/video/SDL_stretch.c index 5fdb317de..9543e4974 100644 --- a/src/video/SDL_stretch.c +++ b/src/video/SDL_stretch.c @@ -468,7 +468,7 @@ get_scaler_datas(int src_nb, int dst_nb, int *fp_start, int *fp_step, int *left_ Sint64 tmp[2]; tmp[0] = (Sint64)step * (x0 >> 16); tmp[1] = (Sint64)step * (x0 & 0xFFFF); - x0 = tmp[0] + ((tmp[1] + 0x8000) >> 16); /* x0 == (step + 1) / 2 */ + x0 = (int) (tmp[0] + ((tmp[1] + 0x8000) >> 16)); /* x0 == (step + 1) / 2 */ #endif /* -= 0.5, get back the pixel origin, in source coordinates */ x0 -= FP_ONE / 2;