[GRASS-SVN] r47560 - grass-addons/grass7/imagery/i.topo.corr
svn_grass at osgeo.org
svn_grass at osgeo.org
Thu Aug 11 16:53:18 EDT 2011
Author: neteler
Date: 2011-08-11 13:53:18 -0700 (Thu, 11 Aug 2011)
New Revision: 47560
Modified:
grass-addons/grass7/imagery/i.topo.corr/illumination.c
grass-addons/grass7/imagery/i.topo.corr/main.c
Log:
more update to G7
Modified: grass-addons/grass7/imagery/i.topo.corr/illumination.c
===================================================================
--- grass-addons/grass7/imagery/i.topo.corr/illumination.c 2011-08-11 20:51:09 UTC (rev 47559)
+++ grass-addons/grass7/imagery/i.topo.corr/illumination.c 2011-08-11 20:53:18 UTC (rev 47560)
@@ -28,7 +28,7 @@
double H, V, dx, dy, key, north, east, south, west, center;
double cos_i, cos_z, sin_z, slope, aspect;
- G_get_set_window(&window);
+ Rast_get_window(&window);
G_begin_distance_calculations();
north = Rast_row_to_northing(0.5, &window);
Modified: grass-addons/grass7/imagery/i.topo.corr/main.c
===================================================================
--- grass-addons/grass7/imagery/i.topo.corr/main.c 2011-08-11 20:51:09 UTC (rev 47559)
+++ grass-addons/grass7/imagery/i.topo.corr/main.c 2011-08-11 20:53:18 UTC (rev 47560)
@@ -105,15 +105,16 @@
/* Evaluate only cos_i raster file */
/* i.topo.corr -i out=cosi.on07 base=SRTM_v2 zenith=33.3631 azimuth=59.8897 */
if (ilum->answer) {
+ Rast_get_window(&window);
azimuth = atof(azim->answer);
/* Warning: make buffers and output after set window */
strcpy(dem.name, base->answer);
dem.fd = Rast_open_old(dem.name, "");
+ dem.type = Rast_get_map_type(dem.fd);
/* Set window to DEM file */
Rast_get_window(&window);
Rast_get_cellhd(dem.name, "", &hd_dem);
Rast_align_window(&window, &hd_dem);
- Rast_set_window(&window);
/* Open and buffer of the output file */
strcpy(out.name, output->answer);
out.fd = Rast_open_new(output->answer, DCELL_TYPE);
More information about the grass-commit
mailing list