1ARDRLN(3NCARG)                   NCAR GRAPHICS                  ARDRLN(3NCARG)
2
3
4

NAME

6       ARDRLN - Draws a polyline that is masked by a given area map.
7

SYNOPSIS

9       CALL ARDRLN (MAP,XCD,YCD,NCD,XCS,YCS,MCS,IAI,IAG,MAI,LPR)
10

C-BINDING SYNOPSIS

12       #include <ncarg/ncargC.h>
13
14       void c_ardrln (int *map, float *xcd, float *ycd, int ncd, float *xcs,
15       float *ycs, int mcs, int *iai, int *iag, int mai, int (*lpr)(float
16       *xcs, float *ycs, int *ncs, int *iai, int *iag, int *nai))
17

DESCRIPTION

19       MAP         (an input/output array of type INTEGER) - An array
20                   containing an area map that has been initialized by a call
21                   to ARINAM and to which edges have been added by calls to
22                   AREDAM.  If you did not preprocess the area map by calling
23                   ARPRAM, ARDRLN calls it before doing anything else.
24
25                   Note: As part of initializing the area map, ARINAM stores
26                   the dimension of MAP in MAP(1); therefore, the dimension
27                   does not have to be given as an argument in calls to
28                   ARDRLN.)
29
30       XCD         (an input array, dimensioned NCD, of type REAL) - The X
31                   coordinates, in the user coordinate system, of the points
32                   defining the polyline.
33
34       YCD         (an input array, dimensioned NCD, of type REAL) - The Y
35                   coordinates, in the user coordinate system, of the points
36                   defining the polyline.
37
38       NCD         (an input expression of type INTEGER) - The number of
39                   points defining the polyline.
40
41       XCS         (a workspace array, dimensioned MCS, of type REAL) - Used
42                   by ARDRLN in calls to LPR, the user-supplied line-
43                   processing routine, to hold the X coordinates of the
44                   polyline segment contained in a given area.
45
46       YCS         (a workspace array, dimensioned MCS, of type REAL) - Used
47                   by ARDRLN in calls to LPR, the user-supplied line-
48                   processing routine, to hold the Y coordinates of the
49                   polyline segment contained in a given area.
50
51       MCS         (an input expression of type INTEGER) - Dimension of each
52                   of the arrays XCS and YCS.
53
54       IAI         (a workspace array, dimensioned MAI, of type INTEGER) - The
55                   area identifier array, used in calls to LPR, the user-
56                   supplied line-processing routine.
57
58       IAG         (a workspace array, dimensioned MAI, of type INTEGER) - The
59                   group identifier array, used in calls to LPR, the user-
60                   supplied line-processing routine.
61
62       MAI         (an input expression of type INTEGER) - Dimension of each
63                   of the arrays IAI and IAG. MAI must be greater than or
64                   equal to n, where n is the number of groups in the area
65                   map.
66
67       LPR         (a subroutine) - A line-processing routine that you supply
68                   for ARDRLN to call. LPR must be declared EXTERNAL in the
69                   routine that calls ARDRLN. LPR must have the following
70                   structure:
71
72                   SUBROUTINE LPR (XCS,YCS,NCS,IAI,IAG,NAI)
73                   DIMENSION XCS(*),YCS(*),IAI(*),IAG(*)
74
75                   (code to process polyline defined by XCS, YCS, IAI, and
76                   IAG)
77
78                   RETURN
79                   END
80
81                   XCS,YCS     (input arrays, dimensioned NCS, of type REAL) -
82                               Hold the X and Y coordinates, in NDCs, of NCS
83                               points defining a piece of the original
84                               polyline that is completely contained in one of
85                               the areas defined by the area map.
86
87                   NCS         (an input expression of type INTEGER) - Number
88                               of X and Y coordinates in the arrays XCS and
89                               YCS.
90
91                   IAI,IAG     (input arrays, dimensioned NAI, of type
92                               INTEGER) - Hold NAI pairs of area identifiers
93                               and group identifiers, respectively, for the
94                               area in which the piece of the polyline lies.
95                               For each value of I from 1 to NAI, IAI(I) is
96                               the area identifier for the area with respect
97                               to the group of edges specified by the group
98                               identifier IAG(I).
99
100                   NAI         (an input expression of type INTEGER) - Number
101                               of values given in IAI and IAG. NAI equals the
102                               number of groups of edges that you put in the
103                               area map.
104
105       Before executing the first call to LPR, ARDRLN calls GETSET to retrieve
106       the current user-system mapping parameters and then executes the
107       following statement:
108
109            CALL SET (VPL,VPR,VPB,VPT,VPL,VPR,VPB,VPT,1)
110
111       where VPL, VPR, VPB, and VPT are the viewport left, right, bottom, and
112       top coordinates in NDCs.
113
114       This ensures correct results if the NDCs in XCS and YCS are used by the
115       line-processing routine LPR in calls to such routines as GPL and CURVE,
116       and it allows for clipping at the edges of the viewport. LPR may make
117       its own SET call to achieve some other effect. Before returning control
118       to the calling routine, ARDRLN calls SET again to restore the original
119       mapping parameters.
120

C-BINDING DESCRIPTION

122       The C-binding argument descriptions are the same as the FORTRAN
123       argument descriptions.
124

EXAMPLES

126       Use the ncargex command to see the following relevant examples:
127       carline, tareas, fsppoint.
128

ACCESS

130       To use ARDRLN or c_ardrln, load the NCAR Graphics libraries ncarg,
131       ncarg_gks, and ncarg_c, preferably in that order.
132

MESSAGES

134       See the areas man page for a description of all Areas error messages
135       and/or informational messages.
136

SEE ALSO

138       Online: areas, areas_params, ardbpa, aredam, argeti, argetr, argtai,
139       arinam, armvam, arpram, arscam, arseti, arsetr, ncarg_cbind
140
141       Hardcopy: NCAR Graphics Contouring and Mapping Tutorial
142
144       Copyright (C) 1987-2009
145       University Corporation for Atmospheric Research
146       The use of this Software is governed by a License Agreement.
147
148
149
150UNIX                              March 1993                    ARDRLN(3NCARG)
Impressum