From cda73633d65016467555d83a12474ba569029092 Mon Sep 17 00:00:00 2001 From: Andrew Murray Date: Thu, 28 Mar 2019 16:10:55 +1100 Subject: [PATCH] Fixed incompatible pointer type warnings --- src/libImaging/Geometry.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/src/libImaging/Geometry.c b/src/libImaging/Geometry.c index 647486eb8..23236a971 100644 --- a/src/libImaging/Geometry.c +++ b/src/libImaging/Geometry.c @@ -29,8 +29,8 @@ ImagingFlipLeftRight(Imaging imOut, Imaging imIn) #define FLIP_LEFT_RIGHT(INT, image) \ for (y = 0; y < imIn->ysize; y++) { \ - INT* in = imIn->image[y]; \ - INT* out = imOut->image[y]; \ + INT* in = (INT *)imIn->image[y]; \ + INT* out = (INT *)imOut->image[y]; \ xr = imIn->xsize-1; \ for (x = 0; x < imIn->xsize; x++, xr--) \ out[xr] = in[x]; \ @@ -105,10 +105,10 @@ ImagingRotate90(Imaging imOut, Imaging imIn) yyysize = yy + ROTATE_SMALL_CHUNK < imIn->ysize ? yy + ROTATE_SMALL_CHUNK : imIn->ysize; \ xxxsize = xx + ROTATE_SMALL_CHUNK < imIn->xsize ? xx + ROTATE_SMALL_CHUNK : imIn->xsize; \ for (yyy = yy; yyy < yyysize; yyy++) { \ - INT* in = imIn->image[yyy]; \ + INT* in = (INT *)imIn->image[yyy]; \ xr = imIn->xsize - 1 - xx; \ for (xxx = xx; xxx < xxxsize; xxx++, xr--) { \ - INT* out = imOut->image[xr]; \ + INT* out = (INT *)imOut->image[xr]; \ out[yyy] = in[xxx]; \ } \ } \ @@ -161,9 +161,9 @@ ImagingTranspose(Imaging imOut, Imaging imIn) yyysize = yy + ROTATE_SMALL_CHUNK < imIn->ysize ? yy + ROTATE_SMALL_CHUNK : imIn->ysize; \ xxxsize = xx + ROTATE_SMALL_CHUNK < imIn->xsize ? xx + ROTATE_SMALL_CHUNK : imIn->xsize; \ for (yyy = yy; yyy < yyysize; yyy++) { \ - INT* in = imIn->image[yyy]; \ + INT* in = (INT *)imIn->image[yyy]; \ for (xxx = xx; xxx < xxxsize; xxx++) { \ - INT* out = imOut->image[xxx]; \ + INT* out = (INT *)imOut->image[xxx]; \ out[yyy] = in[xxx]; \ } \ } \ @@ -217,10 +217,10 @@ ImagingTransverse(Imaging imOut, Imaging imIn) xxxsize = xx + ROTATE_SMALL_CHUNK < imIn->xsize ? xx + ROTATE_SMALL_CHUNK : imIn->xsize; \ yr = imIn->ysize - 1 - yy; \ for (yyy = yy; yyy < yyysize; yyy++, yr--) { \ - INT* in = imIn->image[yyy]; \ + INT* in = (INT *)imIn->image[yyy]; \ xr = imIn->xsize - 1 - xx; \ for (xxx = xx; xxx < xxxsize; xxx++, xr--) { \ - INT* out = imOut->image[xr]; \ + INT* out = (INT *)imOut->image[xr]; \ out[yr] = in[xxx]; \ } \ } \ @@ -264,8 +264,8 @@ ImagingRotate180(Imaging imOut, Imaging imIn) #define ROTATE_180(INT, image) \ for (y = 0; y < imIn->ysize; y++, yr--) { \ - INT* in = imIn->image[y]; \ - INT* out = imOut->image[yr]; \ + INT* in = (INT *)imIn->image[y]; \ + INT* out = (INT *)imOut->image[yr]; \ xr = imIn->xsize-1; \ for (x = 0; x < imIn->xsize; x++, xr--) \ out[xr] = in[x]; \ @@ -317,9 +317,9 @@ ImagingRotate270(Imaging imOut, Imaging imIn) xxxsize = xx + ROTATE_SMALL_CHUNK < imIn->xsize ? xx + ROTATE_SMALL_CHUNK : imIn->xsize; \ yr = imIn->ysize - 1 - yy; \ for (yyy = yy; yyy < yyysize; yyy++, yr--) { \ - INT* in = imIn->image[yyy]; \ + INT* in = (INT *)imIn->image[yyy]; \ for (xxx = xx; xxx < xxxsize; xxx++) { \ - INT* out = imOut->image[xxx]; \ + INT* out = (INT *)imOut->image[xxx]; \ out[yr] = in[xxx]; \ } \ } \