SDL_SoftStretchLinear: fix implicit conversion (bug 5313)

main
Sylvain Becker 2020-12-23 22:02:28 +01:00
parent 15fea33915
commit 7b8d5b7dc3
1 changed files with 1 additions and 1 deletions

View File

@ -468,7 +468,7 @@ get_scaler_datas(int src_nb, int dst_nb, int *fp_start, int *fp_step, int *left_
Sint64 tmp[2]; Sint64 tmp[2];
tmp[0] = (Sint64)step * (x0 >> 16); tmp[0] = (Sint64)step * (x0 >> 16);
tmp[1] = (Sint64)step * (x0 & 0xFFFF); 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 #endif
/* -= 0.5, get back the pixel origin, in source coordinates */ /* -= 0.5, get back the pixel origin, in source coordinates */
x0 -= FP_ONE / 2; x0 -= FP_ONE / 2;