r2d, version 1.06
converts IDRISI Raster images to common desktop publishing formats. Download here. Image values will be scaled to the interval 0 - 255 (with 0 the minimum value of the original image and 255 the maximum). Requirements: - IDRISI .rdc file must be present. - ImageMagick is needed if one of the following is desired: - annotation (-a) - addition of a legend (-l) - resizing (-r) - an output format other than BMP (-f) - Ghostscript fonts are needed if annotation is desired. - Gnuplot is needed for histogram creation (-H option). ImageMagick, Ghostscript and Gnuplot are free software. They can be downloaded from www.imagemagick.org, www.cs.wisc.edu/~ghost, and www.gnuplot.info respectively. The programs must be installed and in your path environment variable. Usage: $ r2d -options -options inputfile.rst where inputfile may contain one or more * as wild cards. Linux only: if you want to use wild cards you will have to give the file name expression in apostrophes ('in*.rst'). If the input file is found in a directory other than the present working directory, be sure to specify the complete (absolute) path. Options: -p: specify a colour palette to be used for the output image. The string following this switch can be one of the following: grey256 (default, will be used if -p option not set) idris256 qual256 quant256 ndvi256 Alternatively, the name (and location) of a palette file can be specified (e.g. -p mypalette.pal). -fx: specify output format, with x one of the following: b = .bmp (default) j = .jpg p = .png t = .tif g = .gif -axyz: annotate image (bottom right corner) with xyz one or some of the following (order of appearance in the image): u = User string. the argument following this option will be used. Several words must be enclosed in " " f = Name of the input file t = Title as given in IDRISI .rdc file n = Nominal image time and date. WARNING: This only works for files with names following the LCRS file name convention! l = LCRS string ("LCRS" at the moment) d = Today`s date m = Minimum and maximum pixel values in the original image. -l: display legend in image -i: invert image (e.g. display clouds white in IR image) -ex: use display extrema given from x with x: r = IDRISI .rdc file s = smoothe the image (2.5 standard deviations), not applicable to histograms u = user defined extrema. The first argument following this option will be the minimum, the second one the maximum value. Note that the -e option has no effect on min/max values given in annotations. These are the real minimum and maximum. -s: apply scaling factor before converting. image values will be multiplied by the factor following this switch before conversion. Note that this option only makes sense in conjunction with the -e option. If the -e option is not set, -s will be ignored. -o: use overlay. the argument following this option is the overlay file. -rx: resize image. Note: pixels will be blurred! (no x) = resizing approximately to the dimensions used for display in IDRISI. u = user defined. The following value specifies either a) the target size of the larger dimension (col or row) in pixels or b) the size of the target frame (COLSxROWS, e.g. 123x456) into which the image will be fitted. -Hx: Create histogram instead of raster image c = cumulative. u = the following argument gives the number of histogram classes desired (default = 100). -t: Move DTP file(s) to the directory specified in the following argument. -dx: display image using ImageMagick when finished. (no x) = display only, nothing else d = delete DTP file after display program closes down. u = the following argument gives the command to launch a user-defined viewer program. -h or --help or /?: show this message and exit. Troubleshooting: - if "font not found (dir)" or similar is returned check your Ghostscript installation. If Ghostscript is properly installed, copy font files to the directory specified in the error message and try again. Note that an output (without inset text) is still produced. Jan Cermak 2003-present cermak < a t > lcrs < d o t > de Bug reports and feature requests welcome.