File: psclip.1

package info (click to toggle)
gmt 4.5.12-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 71,528 kB
  • ctags: 12,619
  • sloc: ansic: 138,042; sh: 4,992; csh: 1,085; makefile: 1,034; asm: 38
file content (257 lines) | stat: -rw-r--r-- 12,073 bytes parent folder | download
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
.TH PSCLIP 1 "Feb 27 2014" "GMT 4.5.13 (SVN)" "Generic Mapping Tools"
.SH NAME
psclip \- To set up polygonal clip paths
.SH SYNOPSIS
\fBpsclip\fP \fIxyfiles\fP \fB\-J\fP\fIparameters\fP \fB\-R\fP\fIwest\fP/\fIeast\fP/\fIsouth\fP/\fInorth\fP[\fBr\fP] 
[ \fB\-B\fP[\fBp\fP|\fBs\fP]\fIparameters\fP ] [ \fB\-E\fP\fIazim\fP/\fIelev\fP ] [ \fB\-K\fP ] [ \fB\-N\fP ] 
[ \fB\-O\fP ] [ \fB\-P\fP ] [ \fB\-T\fP ] [ \fB\-U\fP[\fIjust\fP/\fIdx\fP/\fIdy\fP/][\fBc\fP|\fIlabel\fP] ] [ \fB\-V\fP ] [ \fB\-X\fP[\fBa\fP|\fBc\fP|\fBr\fP][\fIx-shift\fP[\fBu\fP]] ] [ \fB\-Y\fP[\fBa\fP|\fBc\fP|\fBr\fP][\fIy-shift\fP[\fBu\fP]] ] 
[ \fB\-Z\fP\fIzlevel\fP ] [ \fB\-c\fP\fIcopies\fP] [ \fB\-:\fP[\fBi\fP|\fBo\fP] ] [ \fB\-bi\fP[\fBs\fP|\fBS\fP|\fBd\fP|\fBD\fP[\fIncol\fP]|\fBc\fP[\fIvar1\fP\fB/\fP\fI...\fP]] ] [ \fB\-f\fP\fIcolinfo\fP ] [ \fB\-m\fP[\fIflag\fP] ]
.br
.sp
\fBpsclip\fP \fB\-C\fP [ \fB\-K\fP ] [ \fB\-O\fP ]
.SH DESCRIPTION
\fBpsclip\fP reads (x,y) file(s) [or standard input] and draws polygons that are
activated as clipping paths.  Several files may be read to create complex paths
consisting of several non-connecting segments.
Only marks that are subsequently drawn inside the clipping path will be shown. To determine what is inside or
outside the clipping path, \fBpsclip\fP uses the even-odd rule. When a ray drawn from any point, regardless of
direction, crosses the clipping path segments an odd number of times, the point is inside the clipping path.
If the number is even, the point is outside.
The \fB\-N\fP option, reverses the sense of what is the inside and outside of the paths by plotting a clipping
path along the map boundary.
After subsequent plotting, which will be clipped against these paths, the clipping
may be deactivated by running \fBpsclip\fP a second time with the \fB\-C\fP option only.
.TP
\fIxyfiles\fP
ASCII [or binary, see \fB\-b\fP] file(s) with (x,y) values for clip polygons.  If no files are given, the
standard input is read.
.TP
\fB\-C\fP
Mark end of existing clip path.  No input file or projection information are needed.
However, you must supply \fB\-Xa\fP and \fB\-Ya\fP settings if you are using absolute positioning.
.TP
\fB\-J\fP
Selects the map projection. Scale is UNIT/degree, 1:xxxxx, or width in UNIT (upper case modifier).
UNIT is cm, inch, or m, depending on the \fBMEASURE_UNIT\fP setting in \.gmtdefaults4, but this can be
overridden on the command line by appending \fBc\fP, \fBi\fP, or \fBm\fP to the scale/width value.
When central meridian is optional, default is center of longitude range on \fB\-R\fP option.
Default standard parallel is the equator.
For map height, max dimension, or min dimension, append \fBh\fP, \fB+\fP, or \fB-\fP to the width,
respectively.
.br
More details can be found in the \fBpsbasemap\fP man pages.
.br
.sp
\fBCYLINDRICAL PROJECTIONS:\fP
.br
.sp
\fB\-Jc\fP\fIlon0/lat0/scale\fP (Cassini)
.br
\fB\-Jcyl_stere\fP/[\fIlon0/\fP[\fIlat0/\fP]]\fIscale\fP (Cylindrical Stereographic)
.br
\fB\-Jj\fP[\fIlon0/\fP]\fIscale\fP (Miller)
.br
\fB\-Jm\fP[\fIlon0\fP/[\fIlat0/\fP]]\fIscale\fP (Mercator)
.br
\fB\-Jm\fP\fIlon0/lat0/scale\fP (Mercator - Give meridian and standard parallel)
.br
\fB\-Jo\fP[\fBa\fP]\fIlon0/lat0/azimuth/scale\fP (Oblique Mercator - point and azimuth)
.br
\fB\-Jo\fP[\fBb\fP]\fIlon0/lat0/lon1/lat1/scale\fP (Oblique Mercator - two points)
.br
\fB\-Joc\fP\fIlon0/lat0/lonp/latp/scale\fP (Oblique Mercator - point and pole)
.br
\fB\-Jq\fP[\fIlon0/\fP[\fIlat0/\fP]]\fIscale\fP (Cylindrical Equidistant)
.br
\fB\-Jt\fP\fIlon0/\fP[\fIlat0/\fP]\fIscale\fP (TM - Transverse Mercator)
.br
\fB\-Ju\fP\fIzone/scale\fP (UTM - Universal Transverse Mercator)
.br
\fB\-Jy\fP[\fIlon0/\fP[\fIlat0/\fP]]\fIscale\fP (Cylindrical Equal-Area) 
.br
.sp
\fBCONIC PROJECTIONS:\fP
.br
.sp
\fB\-Jb\fP\fIlon0/lat0/lat1/lat2/scale\fP (Albers)
.br
\fB\-Jd\fP\fIlon0/lat0/lat1/lat2/scale\fP (Conic Equidistant)
.br
\fB\-Jl\fP\fIlon0/lat0/lat1/lat2/scale\fP (Lambert Conic Conformal)
.br
\fB\-Jpoly\fP/[\fIlon0/\fP[\fIlat0/\fP]]\fIscale\fP ((American) Polyconic)
.br
.sp
\fBAZIMUTHAL PROJECTIONS:\fP
.br
.sp
\fB\-Ja\fP\fIlon0/lat0\fP[\fI/horizon\fP]\fI/scale\fP (Lambert Azimuthal Equal-Area)
.br
\fB\-Je\fP\fIlon0/lat0\fP[\fI/horizon\fP]\fI/scale\fP (Azimuthal Equidistant)
.br
\fB\-Jf\fP\fIlon0/lat0\fP[\fI/horizon\fP]\fI/scale\fP (Gnomonic)
.br
\fB\-Jg\fP\fIlon0/lat0\fP[\fI/horizon\fP]\fI/scale\fP (Orthographic)
.br
\fB\-Jg\fP\fIlon0/lat0/altitude/azimuth/tilt/twist/Width/Height/scale\fP (General Perspective).
.br
\fB\-Js\fP\fIlon0/lat0\fP[\fI/horizon\fP]\fI/scale\fP (General Stereographic)
.br
.sp
\fBMISCELLANEOUS PROJECTIONS:\fP
.br
.sp
\fB\-Jh\fP[\fIlon0/\fP]\fIscale\fP (Hammer)
.br
\fB\-Ji\fP[\fIlon0/\fP]\fIscale\fP (Sinusoidal)
.br
\fB\-Jkf\fP[\fIlon0/\fP]\fIscale\fP (Eckert IV)
.br
\fB\-Jk\fP[\fBs\fP][\fIlon0/\fP]\fIscale\fP (Eckert VI)
.br
\fB\-Jn\fP[\fIlon0/\fP]\fIscale\fP (Robinson)
.br
\fB\-Jr\fP[\fIlon0/\fP]\fIscale\fP (Winkel Tripel)
.br
\fB\-Jv\fP[\fIlon0/\fP]\fIscale\fP (Van der Grinten)
.br
\fB\-Jw\fP[\fIlon0/\fP]\fIscale\fP (Mollweide)
.br
.sp
\fBNON-GEOGRAPHICAL PROJECTIONS:\fP
.br
.sp
\fB\-Jp\fP[\fBa\fP]\fIscale\fP[\fI/origin\fP][\fBr\fP|\fBz\fP] (Polar coordinates (theta,r))
.br
\fB\-Jx\fP\fIx-scale\fP[\fBd\fP|\fBl\fP|\fBp\fP\fIpow\fP|\fBt\fP|\fBT\fP][\fI/y-scale\fP[\fBd\fP|\fBl\fP|\fBp\fP\fIpow\fP|\fBt\fP|\fBT\fP]] (Linear, log, and power scaling)
.br
.TP
\fB\-R\fP
\fIxmin\fP, \fIxmax\fP, \fIymin\fP, and \fIymax\fP specify the Region of interest.  For geographic
regions, these limits correspond to \fIwest, east, south,\fP and \fInorth\fP and you may specify them
in decimal degrees or in [+-]dd:mm[:ss.xxx][W|E|S|N] format.  Append \fBr\fP if lower left and upper right
map coordinates are given instead of w/e/s/n.  The two shorthands \fB\-Rg\fP and \fB\-Rd\fP 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 \fB\-R\fP 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 \fBTIME_EPOCH\fP and in the selected \fBTIME_UNIT\fP; append \fBt\fP to
\fB\-JX\fP|\fBx\fP), or (b) absolute time of the form [\fIdate\fP]\fBT\fP[\fIclock\fP]
(append \fBT\fP to \fB\-JX\fP|\fBx\fP).  At least one of \fIdate\fP and \fIclock\fP
must be present; the \fBT\fP is always required.  The \fIdate\fP string must be of the form [-]yyyy[-mm[-dd]]
(Gregorian calendar) or yyyy[-Www[-d]] (ISO week calendar), while the \fIclock\fP 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 \fBgmtdefaults\fP). 
.SH OPTIONS
No space between the option flag and the associated arguments.
.sp
.TP
\fB\-B\fP
Sets map boundary annotation and tickmark intervals; see the
\fBpsbasemap\fP man page for all the details.
.TP
\fB\-E\fP
Sets the viewpoint's azimuth and elevation [180/90].\"'
.TP
\fB\-H\fP
Input file(s) has header record(s).  If used, the default number of header records is \fBN_HEADER_RECS\fP.
Use \fB\-Hi\fP if only input data should have header records [Default will write out header records if the
input data have them]. Blank lines and lines starting with # are always skipped.
.TP
\fB\-K\fP
More \fIPostScript\fP code will be appended later [Default terminates the plot system].
.TP
\fB\-N\fP
Invert the sense of what is inside and outside. For example, when using a single path, this means that
only points outside that path will be shown. Cannot be used together with \fB\-B\fP.
.TP
\fB\-O\fP
Selects Overlay plot mode [Default initializes a new plot system].
.TP
\fB\-P\fP
Selects Portrait plotting mode [Default is Landscape, see \fBgmtdefaults\fP to change this].
.TP
\fB\-T\fP
Rather than read any input files, simply turn on clipping for the current map region.
Basically, \fB\-T\fP is a convenient way to run \fBpsclip\fP with
the arguments \fB\-N\fP /dev/null (or, under Windows, \fB\-N\fP NUL). Cannot be used together with \fB\-B\fP.
.TP
\fB\-U\fP
Draw Unix System time stamp on plot.
By adding \fIjust/dx/dy/\fP, the user may specify the justification of the stamp and
where the stamp should fall on the page relative to lower left corner of the plot.
For example, BL/0/0 will align the lower left corner of the time stamp with the lower left corner of the plot.
Optionally, append a \fIlabel\fP, or \fBc\fP (which will plot the command string.).
The \fBGMT\fP parameters \fBUNIX_TIME\fP, \fBUNIX_TIME_POS\fP, and \fBUNIX_TIME_FORMAT\fP can affect the appearance;
see the \fBgmtdefaults\fP man page for details.
The time string will be in the locale set by the environment variable \fBTZ\fP (generally local time).
.TP
\fB\-V\fP
Selects verbose mode, which will send progress reports to stderr [Default runs "silently"].
.TP
\fB\-X\fP \fB\-Y\fP
Shift plot origin relative to the current origin by (\fIx-shift,y-shift\fP) and
optionally append the length unit (\fBc\fP, \fBi\fP, \fBm\fP, \fBp\fP).
You can prepend \fBa\fP to shift the origin back to the original position after plotting,
or prepend  \fBr\fP [Default] to reset the current origin to the new location.
If \fB\-O\fP is used then the default (\fIx-shift,y-shift\fP) is (0,0), otherwise it is
(r1i, r1i) or (r2.5c, r2.5c).
Alternatively, give \fBc\fP to align the center coordinate (x or y) of the plot with the center of the page
based on current page size.
.TP
\fB\-Z\fP
For 3-D projections: Sets the z-level of the polygons [Default is the bottom of the z-axis].
.TP
\fB\-:\fP
Toggles between (longitude,latitude) and (latitude,longitude) input and/or output.  [Default is (longitude,latitude)].
Append \fBi\fP to select input only or \fBo\fP to select output only.  [Default affects both].
.TP
\fB\-bi\fP
Selects binary input.
Append \fBs\fP for single precision [Default is \fBd\fP (double)].
Uppercase \fBS\fP or \fBD\fP will force byte-swapping.
Optionally, append \fIncol\fP, the number of columns in your binary input file
if it exceeds the columns needed by the program.
Or append \fBc\fP if the input file is netCDF. Optionally, append \fIvar1\fP\fB/\fP\fIvar2\fP\fB/\fP\fI...\fP to
specify the variables to be read.
[Default is 2 input columns].
.TP
\fB\-c\fP
Specifies the number of plot copies. [Default is 1].
.TP
\fB\-f\fP
Special formatting of input and/or output columns (time or geographical data).
Specify \fBi\fP or \fBo\fP to make this apply only to input or output [Default applies to both].
Give one or more columns (or column ranges) separated by commas.
Append \fBT\fP (absolute calendar time), \fBt\fP (relative time in chosen \fBTIME_UNIT\fP since \fBTIME_EPOCH\fP),
\fBx\fP (longitude), \fBy\fP (latitude), or \fBf\fP (floating point) to each column
or column range item.  Shorthand \fB\-f\fP[\fBi\fP|\fBo\fP]\fBg\fP means \fB\-f\fP[\fBi\fP|\fBo\fP]0\fBx\fP,1\fBy\fP
(geographic coordinates).
.TP
\fB\-m\fP
Multiple segment file(s).  Segments are separated by a special record.
For ASCII files the first character must be \fIflag\fP [Default is '>'].
For binary files all fields must be NaN and \fB\-b\fP must
set the number of output columns explicitly.  By default the \fB\-m\fP
setting applies to both input and output.  Use \fB\-mi\fP and \fB\-mo\fP
to give separate settings to input and output.
.SH EXAMPLES
To make an overlay \fIPostScript\fP file that will set up a complex clip area to which
subsequent plotting will be confined, run:
.br
.sp
\fBpsclip\fP my_region.xy \fB\-R\fP 0/40/0/40 \fB\-Jm\fP 0.3\fBi\fP \fB\-O\fP \fB\-K\fP > clip_mask_on.ps
.br
.sp
To deactivate the clipping in an existing plotfile, run:
.br
.sp
\fBpsclip\fP \fB\-C\fP \fB\-O\fP >> complex_plot.ps
.SH BUGS
\fBpsclip\fP cannot handle polygons that contain the south or north pole.  For such polygons,
you should split them into two and make each explicitly contain the polar point.  The two
clip polygons will combine to give the desired effect.
.SH "SEE ALSO"
.IR GMT (1),
.IR grdmask (1),
.IR psbasemap (1),
.IR psmask (1)