d.out.file uses d.save, the GRASS PNG or PostScript driver, and gdal_translate to export the currently selected X display monitor to a graphics file of several formats. Output image size can be set prior to export.
PNG and PPM formats are supported directly by the GRASS PNG driver and PostScript output is supported directly by the GRASS PS driver.
TIFF, JPEG, and BMP formats are supported by using gdal_translate on PPM format files produced by the GRASS PNG driver. Different levels of compression/quality are supported for JPEG files.
Graphic files are exported to the user's current working directory by default, but different paths may be specified in the output field.
EPS files are not compatible with d.frame, as it is not possible to nest encapsulation. Only the first frame will be drawn. In these cases it is recommended to output to regular PostScript format and then use a utility like ps2epsi to convert to an EPS file. Output from this module using the regular PostScript format may contain subframes.
g.region rast=slope -p d.mon x0 d.rast slope d.vect streams type=area,line d.barscale at=0,94.5 d.out.file spearfish_pic format=png size=800,600 d.out.file spearfish_pic format=ps -r paper=a4
g.region rast=elevation.dem r.shaded.relief map=elevation.dem shad=elev.shad_relf d.mon x1 d.frame.quarter d.frame uno d.his h=elevation.dem i=elev.shad_relf brighten=50 echo "A" | d.text -b color=black size=10 at=93,5 d.frame dos d.his h=slope i=elev.shad_relf brighten=40 echo "B" | d.text -b color=black size=10 at=93,5 d.frame tres d.his h=landcover.30m i=elev.shad_relf brighten=55 echo "C" | d.text -b color=black size=10 at=93,5 d.frame cuatro d.his h=trn.sites i=elev.shad_relf brighten=15 echo "D" | d.text -b color=black size=10 at=93,5 d.frame full_screen d.out.file spearfish_4 format=ps -r paper=a4
Last changed: $Date: 2007-11-26 20:20:34 -0800 (Mon, 26 Nov 2007) $
Main index - display index - Full index
© 2003-2008 GRASS Development Team