[GRASS-SVN] r41771 - grass-addons/ossim_grass/v.planet
svn_grass at osgeo.org
svn_grass at osgeo.org
Sat Apr 10 07:16:43 EDT 2010
Author: epifanio
Date: 2010-04-10 07:16:42 -0400 (Sat, 10 Apr 2010)
New Revision: 41771
Modified:
grass-addons/ossim_grass/v.planet/v.planet.py
Log:
debug, vector style don't works as aspected
Modified: grass-addons/ossim_grass/v.planet/v.planet.py
===================================================================
--- grass-addons/ossim_grass/v.planet/v.planet.py 2010-04-10 10:49:41 UTC (rev 41770)
+++ grass-addons/ossim_grass/v.planet/v.planet.py 2010-04-10 11:16:42 UTC (rev 41771)
@@ -75,7 +75,7 @@
#% key: pen
#% type: string
#% key_desc: pen
-#% description: brush color
+#% description: pen color
#% required : no
#%end
#%option
@@ -111,7 +111,7 @@
except ImportError:
import osr, ogr, gdal
-from ogrTovrt import ogrvrt, makestile
+from ogrTovrt import ogrvrt #, makestile
def main():
@@ -281,9 +281,25 @@
def makeoverview(input):
os.system("ossim-img2rr %s" % input)
+
+def makestile(outfile, brush, pen, size, fill, thickness):
+ brush = brush.split(',')
+ pen = pen.split(',')
+ size = size.split(',')
+ outfile = outfile.replace('.vrt','')
+ outfile = outfile+'.omd'
+ omd = '// vector file rendering options\n'
+ omd += 'brush_color: %s %s %s \n' % (brush[0], brush[1], brush[2])
+ omd += 'pen_color: %s %s %s \n' % (pen[0], pen[1], pen[2])
+ omd += 'point_width_height: %s %s \n' % (size[0], size[1])
+ omd += 'fill_flag: %s \n' % (fill)
+ omd += 'thickness: %s \n' % (thickness)
+ open(outfile,'w').write(omd)
+ print omd
+
if __name__ == "__main__":
options, flags = grass.parser()
sys.exit(main())
More information about the grass-commit
mailing list