MB-System Unix Manual Page

mbgrdtiff

Section: MB-System 5.0 (1)
Updated: 28 September 2013
Index
 

NAME

mbgrdtiff - generates a geographically located TIFF image from a GMT grid file.

 

VERSION

Version 5.0

 

SYNOPSIS

mbgrdtiff -Ccptfile -Igrdfile -Otiff_file [-H -Kintensfile -V -W]

 

DESCRIPTION

mbgrdtiff generates a TIFF image from a GMT grid. The image generation is similar to that of the GMT program grdimage. In particular, the color map is applied from a GMT CPT file, and shading overlay grids may be applied. The image is 8 bits per pixel if the color map is a grayscale, and 24 bits per pixel otherwise. In order to automatically generate a reasonable image of a grid, use the macro mbm_grdtiff. The program mbgrdtiff recognizes the coordinate system used by mbgrid or mbmosaic to generate a grid file, and then embeds the projection and grid bounds information into the TIFF image in accordance with the GeoTIFF standard. A number of GIS software packages recognize the georeferencing information in GeoTIFF images. In particular, images generated by mbgrdtiff from grids created using mbgrid or mbmosaic can be loaded into the GRASS, ArcInfo, ArcView, and ArcGIS GIS packages as geographically located coverages. The mbgrid and mbmosaic manual pages each contain an appendix with a complete list of the projected coordinate systems that may used in grid generation. Some software packages (e.g. Winfrog) do not recognize the embedded coordinate system information, and install require a parallel "world" file to specify the bounds and resolution. The -W option causes a world file to be generated with a ".tfw" suffix.  

AUTHORSHIP

David W. Caress (caress@mbari.org)

  Monterey Bay Aquarium Research Institute
Dale N. Chayes (dale@ldeo.columbia.edu)

  Lamont-Doherty Earth Observatory

 

OPTIONS

-C
Sets the color palette (CPT) file which controls the color of the plot. See documentation of the GMT package for a complete description of cpt files. If the R, G, and B values in the CPT file are all equal for each data level (i.e. R=G=B), the the output TIFF image will be 8 bits per pixel. Otherwise, the output TIFF image will be 24 bits per pixel.
-H
This "help" flag cause the program to print out a description of its operation and then exit immediately.
-I
grdfile
Sets the name of the gridded data file to be plotted. The data must be in a form acceptable to GMT version 3 programs (see the GMT Cookbook & Technical Reference).
-K
intensity_file
Sets the name of the gridded data file containing intensity values to be used for shading the map. Alternatively, grdfile may be a list of grid files (one filename on each line) to be used together. If a list of files is supplied, the intensity files must conform in order to the list of data grid files they will shade.
-O
root
Sets the root used to construct the filename of the output shellscript (root.cmd) and names of files created when the shellscript is run. Normally the name of the input grid file or grid file list is used as the root.
-V
Selects verbose mode [Default runs "silently"].
-W
The -W option causes a "world" file to be generated parallel to the GeoTiff image with a ".tfw" suffix. Some software packages (e.g. Winfrog) do not recognize the coordinate information embedded in the GeoTiff file, and look for a world file.
 

EXAMPLES

Suppose we have obtained two GRD files called PunaA_bath.grd and PunaA_ss.grd, both with dimensions 1162 x 1068. The file PunaA_bath.grd contains seafloor topography (depth values are negative, ranging from -5035 m to -1619 m), and the file PunaA_ss.grd contains a sidescan mosaic (reflectivity values ranging from 0 to 128 dB). In order to generate a 24 bit color TIFF image of the seafloor topography, we use:

        mbgrdtiff -I PunaA_bath.grd             -O PunaA_bath.tif               -C bath.cpt -V

where the color is controlled by a GMT cpt file bath.cpt containing:

        -5250  37  57 175 -4875  40 127 251

        -4875  40 127 251 -4500  50 190 255

        -4500  50 190 255 -4125 106 235 255

        -4125 106 235 255 -3750 138 236 174

        -3750 138 236 174 -3375 205 255 162

        -3375 205 255 162 -3000 240 236 121

        -3000 240 236 121 -2625 255 189  87

        -2625 255 189  87 -2250 255 161  68

        -2250 255 161  68 -1875 255 186 133

        -1875 255 186 133 -1500 255 255 255

In order to generate an 8 bit grayscale TIFF image of the sidescan mosaic, we use:

        mbgrdtiff -I PunaA_ss.grd               -O PunaA_ss.tif                 -C ss.cpt -V

where the grayscale is controlled by a GMT cpt file ss.cpt containing:

         0.00   0   0   0   16.50  26  26  26

        16.50  26  26  26   22.87  51  51  51

        22.87  51  51  51   27.00  77  77  77

        27.00  77  77  77   30.00 102 102 102

        30.00 102 102 102   32.25 128 128 128

        32.25 128 128 128   34.25 153 153 153

        34.25 153 153 153   36.25 179 179 179

        36.25 179 179 179   38.50 204 204 204

        38.50 204 204 204   41.23 230 230 230

        41.23 230 230 230  128.00 255 255 255

Here greater reflectivity amplitudes are represented by light grayscales.

 

SEE ALSO

mbsystem(1), mbm_grdplot(1), mbgrid(1), mbmosaic(1), mbm_grid(1), mbm_grdtiff(1), gmt(1), grdimage(1)

 

BUGS

Let us know.


 

Index

NAME
VERSION
SYNOPSIS
DESCRIPTION
AUTHORSHIP
OPTIONS
EXAMPLES
SEE ALSO
BUGS


Last Updated: 28 September 2013


Return to list of MB-System manual pages...

Back to MB-System Home Page...