[GRASS-SVN] r33726 - grass-addons/raster/r.sun_horizon/r.sun2
svn_grass at osgeo.org
svn_grass at osgeo.org
Tue Oct 7 09:09:23 EDT 2008
Author: neteler
Date: 2008-10-07 09:09:23 -0400 (Tue, 07 Oct 2008)
New Revision: 33726
Modified:
grass-addons/raster/r.sun_horizon/r.sun2/main.c
Log:
Thomas Huld: don't stop when program compiled with optimization; was calculating the shadowing from horizons wrongly
Modified: grass-addons/raster/r.sun_horizon/r.sun2/main.c
===================================================================
--- grass-addons/raster/r.sun_horizon/r.sun2/main.c 2008-10-07 11:34:18 UTC (rev 33725)
+++ grass-addons/raster/r.sun_horizon/r.sun2/main.c 2008-10-07 13:09:23 UTC (rev 33726)
@@ -1921,14 +1921,12 @@
la_min = AMIN1(la_min, latitude);
latitude *= deg2rad;
}
- if (latin == NULL && lt == NULL) {
- if ((G_projection() != PROJECTION_LL)) {
+ if ((G_projection() != PROJECTION_LL)) {
longitude = gridGeom.xp;
latitude = gridGeom.yp;
- if (pj_do_proj(&longitude, &latitude, &iproj, &oproj) <
- 0) {
+ if (pj_do_proj(&longitude, &latitude, &iproj, &oproj) < 0) {
G_fatal_error("Error in pj_do_proj");
}
@@ -1936,15 +1934,14 @@
la_min = AMIN1(la_min, latitude);
latitude *= deg2rad;
longitude *= deg2rad;
- }
- else { /* ll projection */
+ }
+ else { /* ll projection */
latitude = gridGeom.yp;
longitude = gridGeom.xp;
la_max = AMAX1(la_max, latitude);
la_min = AMIN1(la_min, latitude);
latitude *= deg2rad;
longitude *= deg2rad;
- }
}
if (coefbh != NULL) {
More information about the grass-commit
mailing list