File: node92.html

package info (click to toggle)
gmt-doc 3.4-1.1
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 4,756 kB
  • ctags: 1,800
  • sloc: makefile: 30
file content (185 lines) | stat: -rw-r--r-- 7,065 bytes parent folder | download | duplicates (2)
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
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">

<!--Converted with LaTeX2HTML 99.2beta8 (1.46)
original version by:  Nikos Drakos, CBLU, University of Leeds
* revised and updated by:  Marcus Hennecke, Ross Moore, Herb Swan
* with significant contributions from:
  Jens Lippmann, Marek Rouchal, Martin Wilck and others -->
<HTML>
<HEAD>
<TITLE>6.19 Color patterns on maps</TITLE>
<META NAME="description" CONTENT="6.19 Color patterns on maps">
<META NAME="keywords" CONTENT="GMT_Docs">
<META NAME="resource-type" CONTENT="document">
<META NAME="distribution" CONTENT="global">

<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="LaTeX2HTML v99.2beta8">
<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css">

<LINK REL="STYLESHEET" HREF="GMT_Docs.css">

<LINK REL="next" HREF="node93.html">
<LINK REL="previous" HREF="node91.html">
<LINK REL="up" HREF="node73.html">
<LINK REL="next" HREF="node93.html">
</HEAD>

<BODY  bgcolor="#ffffff">
<!--Navigation Panel-->
<A NAME="tex2html2318"
  HREF="node93.html">
<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" SRC="next.gif"></A> 
<A NAME="tex2html2312"
  HREF="node73.html">
<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" SRC="up.gif"></A> 
<A NAME="tex2html2306"
  HREF="node91.html">
<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" SRC="prev.gif"></A> 
<A NAME="tex2html2314"
  HREF="node1.html">
<IMG WIDTH="65" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="contents" SRC="contents.gif"></A> 
<A NAME="tex2html2316"
  HREF="node149.html">
<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" SRC="index.gif"></A> 
<BR>
<B> Next:</B> <A NAME="tex2html2319"
  HREF="node93.html">6.20 Custom map symbols</A>
<B> Up:</B> <A NAME="tex2html2313"
  HREF="node73.html">6. Cook-book</A>
<B> Previous:</B> <A NAME="tex2html2307"
  HREF="node91.html">6.18 Volumes and Spatial</A>
 &nbsp <B>  <A NAME="tex2html2315"
  HREF="node1.html">Contents</A></B> 
 &nbsp <B>  <A NAME="tex2html2317"
  HREF="node149.html">Index</A></B> 
<BR>
<BR>
<!--End of Navigation Panel-->

<H1><A NAME="SECTION0014190000000000000000"></A>
<A NAME="11992"></A>
<BR>
6.19 Color patterns on maps
</H1>

<P>
<A NAME="tex2html470"
  HREF="http://www.soest.hawaii.edu/gmt"><B>GMT</B></A> 3.1 introduced color patterns and this examples give
a few cases of how to use this new feature.  We make a phony
poster that advertises an international conference on <A NAME="tex2html471"
  HREF="http://www.soest.hawaii.edu/gmt"><B>GMT</B></A> in Honolulu.  We use <A NAME="tex2html472"
  HREF="../grdmath.html"><I><B>grdmath</B></I></A><A NAME="12012"></A>, <A NAME="tex2html473"
  HREF="../makecpt.html"><I><B>makecpt</B></I></A><A NAME="12021"></A>, and
<A NAME="tex2html474"
  HREF="../grdimage.html"><I><B>grdimage</B></I></A><A NAME="12030"></A> to draw pleasing color backgrounds on maps,
and overlay <A NAME="tex2html475"
  HREF="../pscoast.html"><I><B>pscoast</B></I></A><A NAME="12039"></A> clippaths to have the patterns
change at the coastlines.  The middle panel demonstrates a
simple <A NAME="tex2html476"
  HREF="../pscoast.html"><I><B>pscoast</B></I></A><A NAME="12048"></A> call where the built-in pattern # 86
is drawn at 100 dpi but with the black and white pixels
replaced with color combinations.  The final panel repeats
the top panel except that the land and sea images have changed places
(Figure&nbsp;<A HREF="node92.html#fig:GMT_example_19">6.19</A>).

<P>

<P>

<BR>

<P>
<BR CLEAR="ALL">
<HR>
<BR>
<PRE>
gmtset COLOR_MODEL rgb
grdmath -R-180/180/-90/90 -I1 -F Y COSD 2 POW = lat.grd
grdmath -R-180/180/-90/90 -I1 -F X = lon.grd
echo "0 255 255 255 1 0 0 255" &gt;! lat.cpt
makecpt -Crainbow -T-180/180/60 -Z &gt;! lon.cpt
grdimage lat.grd -JI0/6.5i -Clat.cpt -P -K -Y7.5i -B0 &gt;! example_19.ps
pscoast -R -JI -O -K -Dc -A5000 -Gc &gt;&gt; example_19.ps
grdimage lon.grd -JI -Clon.cpt -O -K &gt;&gt; example_19.ps
pscoast -R -JI -O -K -Q &gt;&gt; example_19.ps
pscoast -R -JI -O -K -Dc -A5000 -W0.25p &gt;&gt; example_19.ps
echo "0 20 32 0 1 CM FIRST INTERNATIONAL" | pstext -R -JI -O -K -G255/0/0 -S0.5p &gt;&gt; example_19.ps
echo "0 -10 32 0 1 CM GMT CONFERENCE" | pstext -R -JI -O -K -G255/0/0 -S0.5p &gt;&gt; example_19.ps
echo "0 -30 18 0 1 CM Honolulu, Hawaii, April 1, 2000" | pstext -R -JI -O -K -G0/255/50 -S0.25p \
   &gt;&gt; example_19.ps
pscoast -R -JI -O -K -Dc -A5000 -Gp100/86:F255/0/0B255/255/0 -Sp100/7:F255/0/0B0/0/0 -B0 -Y-3.25i \
   &gt;&gt; example_19.ps
echo "0 15 32 0 1 CM SILLY USES OF" | pstext -R -JI -O -K -G50/255/50 -S0.5p &gt;&gt; example_19.ps
echo "0 -15 32 0 1 CM GMT COLOR PATTERNS" | pstext -R -JI -O -K -G255/0/255 -S0.5p &gt;&gt; example_19.ps
grdimage lon.grd -JI -Clon.cpt -O -K -Y-3.25i -B0 -U"Example 19 in Cookbook" &gt;&gt; example_19.ps
pscoast -R -JI -O -K -Dc -A5000 -Gc &gt;&gt; example_19.ps
grdimage lat.grd -JI -Clat.cpt -O -K &gt;&gt; example_19.ps
pscoast -R -JI -O -K -Q &gt;&gt; example_19.ps
pscoast -R -JI -O -K -Dc -A5000 -W0.25p &gt;&gt; example_19.ps
echo "0 20 32 0 1 CM FIRST INTERNATIONAL" | pstext -R -JI -O -K -G255/0/0 -S0.5p &gt;&gt; example_19.ps
echo "0 -10 32 0 1 CM GMT CONFERENCE" | pstext -R -JI -O -K -G255/0/0 -S0.5p &gt;&gt; example_19.ps
echo "0 -30 18 0 1 CM Honolulu, Hawaii, April 1, 2000" | pstext -R -JI -O -G0/255/50 -S0.25p \
   &gt;&gt; example_19.ps
\rm -f l*.grd l*.cpt .gmt*
</PRE>

<P>
<BR>

<BR>

<P>
<BR CLEAR="ALL">
<HR>
<P></P>
<DIV ALIGN="CENTER"><A NAME="fig:GMT_example_19"></A><A NAME="12128"></A>
<TABLE>
<CAPTION ALIGN="BOTTOM"><STRONG>Figure 6.19:</STRONG>
Using color patterns in illustrations</CAPTION>
<TR><TD><IMG
 WIDTH="375" HEIGHT="558" BORDER="0"
 SRC="img125.gif"
 ALT="\begin{figure}\centering\epsfig{figure=eps/GMT_example_19.eps}\end{figure}"></TD></TR>
</TABLE>
</DIV><P></P>

<P>
<A NAME="12093"></A>

<P>
<HR>
<!--Navigation Panel-->
<A NAME="tex2html2318"
  HREF="node93.html">
<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" SRC="next.gif"></A> 
<A NAME="tex2html2312"
  HREF="node73.html">
<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" SRC="up.gif"></A> 
<A NAME="tex2html2306"
  HREF="node91.html">
<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" SRC="prev.gif"></A> 
<A NAME="tex2html2314"
  HREF="node1.html">
<IMG WIDTH="65" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="contents" SRC="contents.gif"></A> 
<A NAME="tex2html2316"
  HREF="node149.html">
<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" SRC="index.gif"></A> 
<BR>
<B> Next:</B> <A NAME="tex2html2319"
  HREF="node93.html">6.20 Custom map symbols</A>
<B> Up:</B> <A NAME="tex2html2313"
  HREF="node73.html">6. Cook-book</A>
<B> Previous:</B> <A NAME="tex2html2307"
  HREF="node91.html">6.18 Volumes and Spatial</A>
 &nbsp <B>  <A NAME="tex2html2315"
  HREF="node1.html">Contents</A></B> 
 &nbsp <B>  <A NAME="tex2html2317"
  HREF="node149.html">Index</A></B> 
<!--End of Navigation Panel-->
<ADDRESS>
Paul Wessel
2001-04-18
</ADDRESS>
</BODY>
</HTML>