1GFA(3NCARG) NCAR GRAPHICS GFA(3NCARG)
2
3
4
6 GFA (Fill area) - output primitive for filling polygonal areas.
7
9 CALL GFA (N, X, Y)
10
12 #include <ncarg/gks.h>
13
14 void gfill_area(const Gpoint_list *point_list);
15
17 N (Integer, Input) - The number of points in the polygon to
18 be filled. N must be greater than two.
19
20 X (N) (Real Array, Integer) - The X world coordinates of the
21 polygon.
22
23 Y (N) (Real Array, Integer) - The Y world coordinates of the
24 polygon.
25
27 The area to be filled is delimited by the sequence of straight line
28 segments connecting the successive points (X(1), Y(1)), (X(2), Y(2)),
29 ..., (X(N), Y(N)). The last point in the polygon is connected to the
30 first point with a straight line segment in the case that (X(N), Y(N))
31 does not equal (X(l), Y(l)).
32
33 Given a polygon whose edges cross each other, it becomes ambiguous as
34 to what constitutes the "inside" of the polygon. The algorithm used in
35 GKS is as follows: for a given point, draw a ray starting at that point
36 and going to infinity in any direction; if the number of intersections
37 between the ray and the polygon is odd, the point is within the poly‐
38 gon, otherwise it is outside. If the straight line passes through a
39 polygon vertex tangentially, the intersection count is not affected.
40 If a point is within the polygon, it is included in the area to be
41 filled.
42
43 Several interior styles (hollow, solid, and various hatch patterns) can
44 be selected. See the man pages for gsfais and gsfasi for these.
45
46 Note well: By default in GKS, the interior fill style is hollow, or no
47 fill. If you call GFA and do not get a filled interior as you expected,
48 you will probably need to call GSFAIS to set the fill style to some‐
49 thing other than "hollow".
50
52 To use GKS routines, load the NCAR GKS-0A library ncarg_gks.
53
55 Online: gsfais, gsfasi, gscr, gsfaci, gqfais, gqfasi, gfill_area
56
57 Hardcopy: User's Guide for NCAR GKS-0A Graphics; NCAR Graphics Funda‐
58 mentals, UNIX Version
59
61 Copyright (C) 1987-2009
62 University Corporation for Atmospheric Research
63 The use of this Software is governed by a License Agreement.
64
65
66
67UNIX March 1993 GFA(3NCARG)