From 7bc01229e8f5431766e1a0a639347ba626c3c196 Mon Sep 17 00:00:00 2001 From: scuri Date: Tue, 16 Feb 2010 03:05:52 +0000 Subject: *** empty log message *** --- include/im_math.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'include') diff --git a/include/im_math.h b/include/im_math.h index 8e9b3dd..1a05d3d 100644 --- a/include/im_math.h +++ b/include/im_math.h @@ -195,7 +195,7 @@ inline T imBilinearInterpolation(int width, int height, T *map, float xl, float x1 = x0 = 0; t = 0; } - else if (xl > width-0.5) + else if (xl >= width-0.5) { x1 = x0 = width-1; t = 0; @@ -212,7 +212,7 @@ inline T imBilinearInterpolation(int width, int height, T *map, float xl, float y1 = y0 = 0; u = 0; } - else if (yl > height-0.5) + else if (yl >= height-0.5) { y1 = y0 = height-1; u = 0; @@ -244,7 +244,7 @@ inline T imBicubicInterpolation(int width, int height, T *map, float xl, float y float t, u; (void)Dummy; - if (xl > width-0.5) + if (xl >= width-0.5) { X[3] = X[2] = X[1] = width-1; X[0] = X[1]-1; @@ -265,7 +265,7 @@ inline T imBicubicInterpolation(int width, int height, T *map, float xl, float y t = xl - (X[1]+0.5f); } - if (yl > height-0.5) + if (yl >= height-0.5) { Y[3] = Y[2] = Y[1] = height-1; Y[0] = Y[1]-1; -- cgit v1.2.3