Commit ee8a1bde authored by Uwe Schulzweida's avatar Uwe Schulzweida

remapdis, remapnn: set num_srch_bins to 1 (bug fix)

parent b11aae94
......@@ -12,6 +12,7 @@
* remapcon: change max_subseg from 1000 to 100000
* Remapeta: correct humidity up to highest level *nctop* where condensation is allowed
* replace: bug fix for searching of parameter code/name
* remapdis, remapnn: set num_srch_bins to 1 (bug fix) [report: Hamid Benhocine]
* Version 1.3.2 released
2009-04-16 Uwe Schulzweida <Uwe.Schulzweida@zmaw.de>
......
......@@ -660,11 +660,18 @@ void *Remap(void *argument)
*/
if ( gridInqType(gridID1) != GRID_CELL && lremap_num_srch_bins == FALSE )
{
int maxbins = 720;
int ysize1 = gridInqYsize(gridID1);
remap_num_srch_bins = ysize1/2 + ysize1%2;
if ( remap_num_srch_bins > maxbins ) remap_num_srch_bins = maxbins;
if ( remap_num_srch_bins < 1 ) remap_num_srch_bins = 1;
if ( map_type == MAP_TYPE_DISTWGT || map_type == MAP_TYPE_DISTWGT1 )
{
remap_num_srch_bins = 1;
}
else
{
int maxbins = 720;
int ysize1 = gridInqYsize(gridID1);
remap_num_srch_bins = ysize1/2 + ysize1%2;
if ( remap_num_srch_bins > maxbins ) remap_num_srch_bins = maxbins;
if ( remap_num_srch_bins < 1 ) remap_num_srch_bins = 1;
}
}
remaps[r].grid.restrict_type = remap_restrict_type;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment