/usr/share/doc/gmt/html/man/gmt2rgb.html is in gmt-doc 4.5.12-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 | <!-- Creator : groff version 1.22.2 -->
<!-- CreationDate: Thu Feb 27 18:11:52 2014 -->
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta name="generator" content="groff -Thtml, see www.gnu.org">
<meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
<meta name="Content-Style" content="text/css">
<style type="text/css">
p { margin-top: 0; margin-bottom: 0; vertical-align: top }
pre { margin-top: 0; margin-bottom: 0; vertical-align: top }
table { margin-top: 0; margin-bottom: 0; vertical-align: top }
h1 { text-align: center }
</style>
<title>GMT2RGB</title>
</head>
<body bgcolor="#ffffff">
<h1 align="center">GMT2RGB</h1>
<a href="#NAME">NAME</a><br>
<a href="#SYNOPSIS">SYNOPSIS</a><br>
<a href="#DESCRIPTION">DESCRIPTION</a><br>
<a href="#OPTIONS">OPTIONS</a><br>
<a href="#EXAMPLES">EXAMPLES</a><br>
<a href="#SEE ALSO">SEE ALSO</a><br>
<hr>
<h2>NAME
<a name="NAME"></a>
</h2>
<p style="margin-left:11%; margin-top: 1em">gmt2rgb −
Converting a grid file, a raw, or a Sun raster file to r/g/b
grids</p>
<h2>SYNOPSIS
<a name="SYNOPSIS"></a>
</h2>
<p style="margin-left:11%; margin-top: 1em"><b>gmt2rgb</b>
<i>infile</i> <b>−G</b><i>template</i> [
<b>−C</b><i>cptfile</i> ] [ <b>−F</b> ] [
<b>−I</b><i>xinc</i>[<b>m</b>|<b>c</b>][/<i>yinc</i>[<b>m</b>|<b>c</b>]]
] [ <b>−L</b><i>layer</i> ] [
<b>−R</b><i>xmin</i>/<i>xmax</i>/<i>ymin</i>/<i>ymax</i>[<b>r</b>]
] [ <b>−V</b> ] [
<b>−W</b><i>width</i>/<i>height</i>[/<i>n_bytes</i>]
]</p>
<h2>DESCRIPTION
<a name="DESCRIPTION"></a>
</h2>
<p style="margin-left:11%; margin-top: 1em"><b>gmt2rgb</b>
reads one of three types of input files: (1) A Sun 8-, 24-,
or 32-bit raster file; we the write out the red, green, and
blue components (0-255 range) to separate grid files. Since
the raster file header is limited you may use the
<b>−R</b>, <b>−F</b>, <b>−I</b> options to
set a complete header record [Default is simply based on the
number of rows and columns]. (2) A binary 2-D grid file; we
then convert the z-values to red, green, blue via the
provided cpt file. Optionally, only write out one of the r,
g, b, layers. (3) A RGB or RGBA raw raster file. Since raw
rasterfiles have no header, you have to give the image
dimensions via the <b>−W</b> option.</p>
<table width="100%" border="0" rules="none" frame="void"
cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="9%">
<p><i>infile</i></p></td>
<td width="2%"></td>
<td width="78%">
<p>The (1) Sun raster file, (2) 2-D binary grid file, or
(3) raw raster file to be converted.</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="9%">
<p><b>−G</b></p></td>
<td width="2%"></td>
<td width="78%">
<p>Provide an output name template for the three output
grids. The template should be a regular grid file name
except it must contain the string %c which on output will be
replaced by r, g, or b.</p></td></tr>
</table>
<h2>OPTIONS
<a name="OPTIONS"></a>
</h2>
<table width="100%" border="0" rules="none" frame="void"
cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="3%">
<p style="margin-top: 1em"><b>−C</b></p></td>
<td width="8%"></td>
<td width="78%">
<p style="margin-top: 1em">name of the color palette table
(for 2-D binary input grid only).</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="3%">
<p><b>−F</b></p></td>
<td width="8%"></td>
<td width="78%">
<p>Force pixel node registration [Default is gridline
registration]. (Node registrations are defined in <b><A HREF="GMT.html">GMT</A></b>
Cookbook Appendix B on grid file formats.)</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="3%">
<p><b>−I</b></p></td>
<td width="8%"></td>
<td width="78%">
<p><i>x_inc</i> [and optionally <i>y_inc</i>] is the grid
spacing. Optionally, append a suffix modifier.
<b>Geographical (degrees) coordinates</b>: Append <b>m</b>
to indicate arc minutes or <b>c</b> to indicate arc seconds.
If one of the units <b>e</b>, <b>k</b>, <b>i</b>, or
<b>n</b> is appended instead, the increment is assumed to be
given in meter, km, miles, or nautical miles, respectively,
and will be converted to the equivalent degrees longitude at
the middle latitude of the region (the conversion depends on
<b><A HREF="gmtdefaults.html#ELLIPSOID">ELLIPSOID</A></b>). If /<i>y_inc</i> is given but set to 0 it
will be reset equal to <i>x_inc</i>; otherwise it will be
converted to degrees latitude. <b>All coordinates</b>: If
<b>=</b> is appended then the corresponding max <i>x</i>
(<i>east</i>) or <i>y</i> (<i>north</i>) may be slightly
adjusted to fit exactly the given increment [by default the
increment may be adjusted slightly to fit the given domain].
Finally, instead of giving an increment you may specify the
<i>number of nodes</i> desired by appending <b>+</b> to the
supplied integer argument; the increment is then
recalculated from the number of nodes and the domain. The
resulting increment value depends on whether you have
selected a gridline-registered or pixel-registered grid; see
Appendix B for details. Note: if
<b>−R</b><i>grdfile</i> is used then grid spacing has
already been initialized; use <b>−I</b> to override
the values.</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="3%">
<p><b>−L</b></p></td>
<td width="8%"></td>
<td width="78%">
<p>Output only the specified layer (r, g, or b). [Default
outputs all 3 layers].</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="3%">
<p><b>−R</b></p></td>
<td width="8%"></td>
<td width="78%">
<p><i>xmin</i>, <i>xmax</i>, <i>ymin</i>, and <i>ymax</i>
specify the Region of interest. For geographic regions,
these limits correspond to <i>west, east, south,</i> and
<i>north</i> and you may specify them in decimal degrees or
in [+-]dd:mm[:ss.xxx][W|E|S|N] format. Append <b>r</b> if
lower left and upper right map coordinates are given instead
of w/e/s/n. The two shorthands <b>−Rg</b> and
<b>−Rd</b> stand for global domain (0/360 and
-180/+180 in longitude respectively, with -90/+90 in
latitude). Alternatively, specify the name of an existing
grid file and the <b>−R</b> settings (and grid
spacing, if applicable) are copied from the grid. For
calendar time coordinates you may either give (a) relative
time (relative to the selected <b><A HREF="gmtdefaults.html#TIME_EPOCH">TIME_EPOCH</A></b> and in the
selected <b><A HREF="gmtdefaults.html#TIME_UNIT">TIME_UNIT</A></b>; append <b>t</b> to
<b>−JX</b>|<b>x</b>), or (b) absolute time of the form
[<i>date</i>]<b>T</b>[<i>clock</i>] (append <b>T</b> to
<b>−JX</b>|<b>x</b>). At least one of <i>date</i> and
<i>clock</i> must be present; the <b>T</b> is always
required. The <i>date</i> string must be of the form
[-]yyyy[-mm[-dd]] (Gregorian calendar) or yyyy[-Www[-d]]
(ISO week calendar), while the <i>clock</i> string must be
of the form hh:mm:ss[.xxx]. The use of delimiters and their
type and positions must be exactly as indicated (however,
input, output and plot formats are customizable; see
<b><A HREF="gmtdefaults.html">gmtdefaults</A></b>).</p> </td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="3%">
<p><b>−V</b></p></td>
<td width="8%"></td>
<td width="78%">
<p>Selects verbose mode, which will send progress reports
to stderr [Default runs "silently"].</p></td></tr>
<tr valign="top" align="left">
<td width="11%"></td>
<td width="3%">
<p><b>−W</b></p></td>
<td width="8%"></td>
<td width="78%">
<p>Sets the size of the raw raster file. By default an RGB
file (which has 3 bytes/pixel) is assumed. For RGBA files
use <i>n_bytes</i> = 4. Use <b>−W</b> for guessing the
image size of a RGB raw file, and
<b>−W</b><i>=/=/4</i> if the raw image is of the RGBA
type. Notice that this might be a bit slow because the
guessing algorithm makes uses of FFTs.</p></td></tr>
</table>
<h2>EXAMPLES
<a name="EXAMPLES"></a>
</h2>
<p style="margin-left:11%; margin-top: 1em">To use the
color palette topo.cpt to create r, g, b component grids
from hawaii_grv.grd file, use</p>
<p style="margin-left:11%; margin-top: 1em"><b>gmt2rgb</b>
hawaii_grv.grd <b>−C</b> topo.cpt <b>−G</b>
hawaii_grv_%c.grd</p>
<p style="margin-left:11%; margin-top: 1em">To output the
red component from the Sun raster radiation.ras file,
use</p>
<p style="margin-left:11%; margin-top: 1em"><b>gmt2rgb</b>
radiation.ras <b>−L</b> r <b>−G</b>
comp_%c.grd</p>
<h2>SEE ALSO
<a name="SEE ALSO"></a>
</h2>
<p style="margin-left:11%; margin-top: 1em"><i><A HREF="gmtdefaults.html">gmtdefaults</A></i>(1),
<i><A HREF="GMT.html">GMT</A></i>(1), <i><A HREF="grdedit.html">grdedit</A></i>(1), <i><A HREF="grdimage.html">grdimage</A></i>(1),
<i><A HREF="grdmath.html">grdmath</A></i>(1), <i><A HREF="grdview.html">grdview</A></i>(1)</p>
<hr>
</body>
</html>
|