[GRASS-SVN] r33952 -
grass/branches/develbranch_6/raster/r.resamp.stats
svn_grass at osgeo.org
svn_grass at osgeo.org
Tue Oct 21 14:32:52 EDT 2008
Author: neteler
Date: 2008-10-21 14:32:52 -0400 (Tue, 21 Oct 2008)
New Revision: 33952
Modified:
grass/branches/develbranch_6/raster/r.resamp.stats/main.c
Log:
glynn: Add an extra row and column to moving window to protect against rounding errors (merge from trunk, r33951)
Modified: grass/branches/develbranch_6/raster/r.resamp.stats/main.c
===================================================================
--- grass/branches/develbranch_6/raster/r.resamp.stats/main.c 2008-10-21 18:25:44 UTC (rev 33951)
+++ grass/branches/develbranch_6/raster/r.resamp.stats/main.c 2008-10-21 18:32:52 UTC (rev 33952)
@@ -315,8 +315,8 @@
G_set_window(&src_w);
- row_scale = 1 + ceil(dst_w.ns_res / src_w.ns_res);
- col_scale = 1 + ceil(dst_w.ew_res / src_w.ew_res);
+ row_scale = 2 + ceil(dst_w.ns_res / src_w.ns_res);
+ col_scale = 2 + ceil(dst_w.ew_res / src_w.ew_res);
/* allocate buffers for input rows */
bufs = G_malloc(row_scale * sizeof(DCELL *));
More information about the grass-commit
mailing list