summaryrefslogtreecommitdiff
path: root/src/lib/evas/common
diff options
context:
space:
mode:
authorCedric BAIL <cedric@osg.samsung.com>2016-12-15 11:28:17 -0800
committerCedric BAIL <cedric@osg.samsung.com>2016-12-15 11:28:17 -0800
commit224ba8586b3cde4ed414e5a99b4edd9f812e8429 (patch)
treec35b63aaf3ed22b6775fcb6a538d8bd88df2db15 /src/lib/evas/common
parente1843b2ced2f0061840c5ddfc1c6b08ca17c4fb9 (diff)
evas: fix use of signed and unsigned type in conditional expression warning.
Diffstat (limited to 'src/lib/evas/common')
-rw-r--r--src/lib/evas/common/evas_image_main.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/lib/evas/common/evas_image_main.c b/src/lib/evas/common/evas_image_main.c
index d9330f0ad0..11588ad02f 100644
--- a/src/lib/evas/common/evas_image_main.c
+++ b/src/lib/evas/common/evas_image_main.c
@@ -186,7 +186,7 @@ _evas_common_rgba_image_plane_get(const RGBA_Image *im, int plane, Eina_Slice *s
186{ 186{
187 unsigned char **csdata = NULL; 187 unsigned char **csdata = NULL;
188 Evas_Colorspace cs; 188 Evas_Colorspace cs;
189 int w, h; 189 size_t w, h;
190 190
191 if (!im || !slice) return EINA_FALSE; 191 if (!im || !slice) return EINA_FALSE;
192 cs = im->cache_entry.space; 192 cs = im->cache_entry.space;
@@ -251,7 +251,7 @@ _evas_common_rgba_image_plane_get(const RGBA_Image *im, int plane, Eina_Slice *s
251 case EVAS_COLORSPACE_YCBCR422601_PL: 251 case EVAS_COLORSPACE_YCBCR422601_PL:
252 if (plane != 0) return EINA_FALSE; 252 if (plane != 0) return EINA_FALSE;
253 slice->mem = csdata[0]; 253 slice->mem = csdata[0];
254 slice->len = (h > 1) ? ((size_t) (csdata[1] - csdata[0]) * h * 2) : (w * 2); 254 slice->len = (h > 1) ? ((csdata[1] - csdata[0]) * h * 2) : (w * 2);
255 return EINA_TRUE; 255 return EINA_TRUE;
256 256
257 // 2 planes 257 // 2 planes
@@ -260,13 +260,13 @@ _evas_common_rgba_image_plane_get(const RGBA_Image *im, int plane, Eina_Slice *s
260 if (plane == 0) 260 if (plane == 0)
261 { 261 {
262 slice->mem = csdata[0]; 262 slice->mem = csdata[0];
263 slice->len = (h > 1) ? ((size_t) (csdata[1] - csdata[0]) * h) : w; 263 slice->len = (h > 1) ? ((csdata[1] - csdata[0]) * h) : w;
264 return EINA_TRUE; 264 return EINA_TRUE;
265 } 265 }
266 else if (plane == 1) 266 else if (plane == 1)
267 { 267 {
268 slice->mem = csdata[h]; 268 slice->mem = csdata[h];
269 slice->len = (h > 1) ? ((size_t) (csdata[h+1] - csdata[h]) * h / 2) : w / 2; 269 slice->len = (h > 1) ? ((csdata[h+1] - csdata[h]) * h / 2) : w / 2;
270 return EINA_TRUE; 270 return EINA_TRUE;
271 } 271 }
272 return EINA_FALSE; 272 return EINA_FALSE;
@@ -277,19 +277,19 @@ _evas_common_rgba_image_plane_get(const RGBA_Image *im, int plane, Eina_Slice *s
277 if (plane == 0) 277 if (plane == 0)
278 { 278 {
279 slice->mem = csdata[0]; 279 slice->mem = csdata[0];
280 slice->len = (h > 1) ? ((size_t) (csdata[1] - csdata[0]) * h) : w; 280 slice->len = (h > 1) ? ((csdata[1] - csdata[0]) * h) : w;
281 return EINA_TRUE; 281 return EINA_TRUE;
282 } 282 }
283 else if (plane == 1) 283 else if (plane == 1)
284 { 284 {
285 slice->mem = csdata[h]; 285 slice->mem = csdata[h];
286 slice->len = (h > 1) ? ((size_t) (csdata[h+1] - csdata[h]) * h / 2) : w / 2; 286 slice->len = (h > 1) ? ((csdata[h+1] - csdata[h]) * h / 2) : w / 2;
287 return EINA_TRUE; 287 return EINA_TRUE;
288 } 288 }
289 else if (plane == 2) 289 else if (plane == 2)
290 { 290 {
291 slice->mem = csdata[h + h / 2]; 291 slice->mem = csdata[h + h / 2];
292 slice->len = (h > 1) ? ((size_t) (csdata[h+h/2+1] - csdata[h+h/2]) * h / 2) : w / 2; 292 slice->len = (h > 1) ? ((csdata[h+h/2+1] - csdata[h+h/2]) * h / 2) : w / 2;
293 return EINA_TRUE; 293 return EINA_TRUE;
294 } 294 }
295 return EINA_FALSE; 295 return EINA_FALSE;