[GRASS-SVN] r36861 - grass/branches/releasebranch_6_4/scripts/r.shaded.relief

svn_grass at osgeo.org svn_grass at osgeo.org
Wed Apr 22 07:00:55 EDT 2009


Author: hamish
Date: 2009-04-22 07:00:55 -0400 (Wed, 22 Apr 2009)
New Revision: 36861

Modified:
   grass/branches/releasebranch_6_4/scripts/r.shaded.relief/r.shaded.relief
Log:
allow alt and az to be floats (merge from devbr6)

Modified: grass/branches/releasebranch_6_4/scripts/r.shaded.relief/r.shaded.relief
===================================================================
--- grass/branches/releasebranch_6_4/scripts/r.shaded.relief/r.shaded.relief	2009-04-22 10:58:18 UTC (rev 36860)
+++ grass/branches/releasebranch_6_4/scripts/r.shaded.relief/r.shaded.relief	2009-04-22 11:00:55 UTC (rev 36861)
@@ -66,7 +66,7 @@
 #% end
 #% option
 #%  key: altitude
-#%  type: integer
+#%  type: double
 #%  description: Altitude of the sun in degrees above the horizon
 #%  required : no
 #%  options : 0-90
@@ -74,7 +74,7 @@
 #% end
 #% option
 #%  key: azimuth
-#%  type: integer
+#%  type: double
 #%  description: Azimuth of the sun in degrees to the east of north
 #%  required : no
 #%  options : 0-360
@@ -179,7 +179,8 @@
 fi		
 
 #correct azimuth to East (GRASS convention):
-az=`expr $az - 90`
+#  this seems to be backwards, but in fact it works so leave it.
+az=`echo "$az" | awk '{print $1 - 90.0}'`
 
 g.message "Calculating shading, please stand by."
 



More information about the grass-commit mailing list