From 438cde4e70084de9264c37dfe32f3884ad31afea Mon Sep 17 00:00:00 2001 From: Mathieu Malaterre Date: Mon, 26 Mar 2012 13:01:41 +0000 Subject: [PATCH] [trunk] remove simple warnings. --- applications/jpip/libopenjpip/imgreg_manager.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/applications/jpip/libopenjpip/imgreg_manager.c b/applications/jpip/libopenjpip/imgreg_manager.c index 3bdca31f..ada6302b 100644 --- a/applications/jpip/libopenjpip/imgreg_manager.c +++ b/applications/jpip/libopenjpip/imgreg_manager.c @@ -77,8 +77,8 @@ imgreg_param_t map_viewin2imgreg( const int fx, const int fy, imgreg.sy = imgreg.fy; } else{ - px = ceil((double)((rx+rw)*imgreg.fx)/(double)fx); - py = ceil((double)((ry+rh)*imgreg.fy)/(double)fy); + px = (int)ceil((double)((rx+rw)*imgreg.fx)/(double)fx); + py = (int)ceil((double)((ry+rh)*imgreg.fy)/(double)fy); if( imgreg.fx < px) px = imgreg.fx; @@ -113,10 +113,10 @@ void find_level( int maxlev, int *lev, int *fx, int *fy, int *xmin, int *ymin, i } else if( *lev < maxlev-1 && ( *fx < xwidth || *fy < ywidth)) { /* Simulate the ceil function. */ - *xmin = ceil((double)*xmin/(double)2.0); - *ymin = ceil((double)*ymin/(double)2.0); - *xmax = ceil((double)*xmax/(double)2.0); - *ymax = ceil((double)*ymax/(double)2.0); + *xmin = (int)ceil((double)*xmin/(double)2.0); + *ymin = (int)ceil((double)*ymin/(double)2.0); + *xmax = (int)ceil((double)*xmax/(double)2.0); + *ymax = (int)ceil((double)*ymax/(double)2.0); (*lev) ++; find_level ( maxlev, lev, fx, fy, xmin, ymin, xmax, ymax);