FORTRAN (**libfgl.a**)

void polf(Int32n, Coordparray[ ][3])

void polfi(Int32n, Icoordparray[ ][3])

void polfs(Int32n, Scoordparray[ ][3])

void polf2(Int32n, Coordparray[ ][2])

void polf2i(Int32n, Icoordparray[ ][2])

void polf2s(Int32n, Scoordparray[ ][2])

SUBROUTINE POLF(n,parray)INTEGER*4nREALparray(3,n)

SUBROUTINE POLFI(n,parray)INTEGER*4nINTEGER*4parray(3,n)

SUBROUTINE POLFS(n,parray)INTEGER*4nINTEGER*2parray(3,n)

SUBROUTINE POLF2(n,parray)INTEGER*4nREALparray(2,n)

SUBROUTINE POLF2I(n,parray)INTEGER*4nINTEGER*4parray(2,n)

SUBROUTINE POLF2S(n,parray)INTEGER*4nINTEGER*2parray(2,n)

The **polf** subroutine draws
filled polygons
using the current area attributes: pattern,
color, and
writemask. Polygons are represented as arrays of points. The first and last points automatically connect to close a polygon. After the polygon is filled, the
current graphics position is set to the first point in the array.

Polygons in 2-D are drawn with *z *= 0.

The six different forms for the **polf** subroutine are as follows:

2-D |
3-D | |

Int16 | polf2s | polfs |

Int32 | polf2i | polfi |

float | polf2 | polf |

The syntax for each of the subroutine forms is the same except for the first argument. They differ only in that **polf** expects real coordinates, **polfi** expects integer coordinates, and **polfs** expects short integer coordinates. In addition, the **polf2** routines assume a 2-D point instead of a 3-D point.

There can be no more than 256 vertices in a polygon. In addition, the **polf** subroutine cannot correctly draw polygons that intersect themselves.

n |
Specifies the number of points in the polygon. |

parray |
Specifies an array containing the vertices of the polygon. |

The example C language program **tpbig.c** uses the **polf2i** subroutine to draw an ice cream cone.

This subroutine is part of GL in the AIXwindows Environment/6000 Version 1, Release 2 with AIXwindows/3D Feature.

/usr/include/gl/gl.h |
Contains C language constant and variable type definitions for GL. |

/usr/include/gl/fgl.h |
Contains FORTRAN constant and variable type definitions for GL. |

Allowing the system to draw concave polygons with the **concave** subroutine.

Specifying the next point in a polygon with the **pdr** subroutine.

Specifying the starting point for a polygon with the **pmv** subroutine.

Drawing a polygon with the **poly** subroutine.

Drawing a filled rectangle with the **rectf** subroutine.

Drawing a rectangle with the **rect** subroutine.

Drawing a relative polygon with the **rpdr** subroutine.

Moving the current graphics position to a starting point for a filled polygon relative to the current point with the **rpmv** subroutine.

AIX Graphics Library Overview, Setting Drawing Attributes, and Drawing Rectangles, Circles, Arcs, and Polygons.