Syntax
[C/C++:]
void gFillPolygonBy2D(int npts, GPOINT *points2);
void gFillPolygonBy3D(int npts, GPOINT3 *points3);
void gFillPolygonTo2D(int npts, GPOINT *points2);
void gFillPolygonTo3D(int npts, GPOINT3 *points3);
void gFillPolygonBy2D(int fill, int line, int inv, int npts, GPOINT *points2);
void gFillPolygonBy3D(int fill, int line, int inv, int npts, GPOINT3 *points3);
void gFillPolygonTo2D(int fill, int line, int inv, int npts, GPOINT *points2);
void gFillPolygonTo3D(int fill, int line, int inv, int npts, GPOINT3 *points3);
[F90:]
subroutine gFillPolygonBy2D(npts, points2)
subroutine gFillPolygonBy3D(npts, points3)
subroutine gFillPolygonTo2D(npts, points2)
subroutine gFillPolygonTo3D(npts, points3)
subroutine gFillPolygonBy2D(fill ,line, inv, npts, points2)
subroutine gFillPolygonBy3D(fill, line, inv, npts, points3)
subroutine gFillPolygonTo2D(fill, line, inv, npts, points2)
subroutine gFillPolygonTo3D(fill, line, inv, npts, points3)
integer, intent(in) :: fill,line,inv,npts
type (GPOINT), intent(in) :: points2(*)
type (GPOINT3), intent(in) :: points3(*)
Arguments
fill
Local polygon fill style (see gSetFillAttribs)
|
= 1 - 256, |
Fill style index (hardware fill) or hatch style index (software fill) |
|
> 256, |
Fill style index (hardware fill) or solid fill (software fill) |
line
Local polygon fill line style (see gSetFillAttribs)
|
= GCURRENT, |
Current line style |
|
= 1 - 256, |
Line style index |
|
> 256, |
Current line style |
inv
Local polygon inverse fill flag (see gSetFillAttribs)
|
= GINVERSE, |
Fill all but polygons (inverse fill) |
npts
Number of points in
points array
points2,points3
2D or 3D coordinate arrays specifying relative or absolute points of polygon boundary
Description
The gFillPolygon set of routines fill a single polygonal area without the need to declare any workspace. Coordinates may be supplied as relative or absolute coordinates in 2 or 3 dimensions. Whether relative or absolute coordinates are used, the complete polygon includes the current drawing position, all the points in the array
points2/3 and an additional point (if necessary) to ensure the last point is the same as the first point. All the points are then clipped to the current clipping limits.
Up to 2048 points can be used to define the polygon and if
npts is greater than this, an error message is generated and no output is done.
The routines may be used with the global filling attributes, set by gSetFillAttribs(), or locally overridding the filling attributes by including the
fill,
line and
inv arguments.
The current position is restored to that prior to calling one of these routines.
See Also
gFillPolygonBy2D UsagegSetFillAttribsgSetFillMode
gDefineHatchStylegDefineLineStyle