[gegl] cast to gint
- From: Nicolas Robidoux <nrobidoux src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gegl] cast to gint
- Date: Wed, 12 Dec 2012 18:35:22 +0000 (UTC)
commit 06cd58a07fa862fff202e8eb111135f4dfbbed67
Author: Nicolas Robidoux <nrobidoux git gnome org>
Date: Wed Dec 12 13:35:11 2012 -0500
cast to gint
gegl/buffer/gegl-sampler.c | 18 ++++++++++--------
1 files changed, 10 insertions(+), 8 deletions(-)
---
diff --git a/gegl/buffer/gegl-sampler.c b/gegl/buffer/gegl-sampler.c
index 629191d..9b93ed1 100644
--- a/gegl/buffer/gegl-sampler.c
+++ b/gegl/buffer/gegl-sampler.c
@@ -265,10 +265,10 @@ gegl_sampler_get_ptr (GeglSampler *const sampler,
fetch_rectangle.x =
x + sampler->context_rect[0].x -
- (maximum_width_and_height - sampler->context_rect[0].width ) / 8;
+ (maximum_width_and_height - sampler->context_rect[0].width ) / (gint) 8;
fetch_rectangle.y =
y + sampler->context_rect[0].y -
- (maximum_width_and_height - sampler->context_rect[0].height) / 8;
+ (maximum_width_and_height - sampler->context_rect[0].height) / (gint) 8;
fetch_rectangle.width = maximum_width_and_height;
fetch_rectangle.height = maximum_width_and_height;
@@ -343,10 +343,10 @@ gegl_sampler_get_from_buffer (GeglSampler *const sampler,
*/
GeglRectangle fetch_rectangle;
- fetch_rectangle.x =
- x - (maximum_width_and_height - sampler->context_rect[0].width ) / 8;
- fetch_rectangle.y =
- y - (maximum_width_and_height - sampler->context_rect[0].height) / 8;
+ fetch_rectangle.x = x -
+ (maximum_width_and_height - sampler->context_rect[0].width ) / (gint) 8;
+ fetch_rectangle.y = y -
+ (maximum_width_and_height - sampler->context_rect[0].height) / (gint) 8;
fetch_rectangle.width = maximum_width_and_height;
fetch_rectangle.height = maximum_width_and_height;
@@ -433,10 +433,12 @@ gegl_sampler_get_from_mipmap (GeglSampler *const sampler,
fetch_rectangle.x =
x + sampler->context_rect[level].x -
- (maximum_width_and_height - sampler->context_rect[level].width ) / 8;
+ (maximum_width_and_height - sampler->context_rect[level].width ) /
+ (gint) 8;
fetch_rectangle.y =
y + sampler->context_rect[level].y -
- (maximum_width_and_height - sampler->context_rect[level].height) / 8;
+ (maximum_width_and_height - sampler->context_rect[level].height) /
+ (gint) 8;
fetch_rectangle.width = maximum_width_and_height;
fetch_rectangle.height = maximum_width_and_height;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]