This subroutine will fill the given polygon and/or draw a borderline surrounding the shape of the polygon. Both, filling and border are optional and may be disabled to get the results you want.
SYNTAX:
FillPolygon srcPolyX%(), srcPolyY%(), fc&&, sc&&
INPUTS:
srcPolyX%(), srcPolyY%() (INTEGER arrays)
- These are 1-dimensional arrays containing the x/y coordinates of the source polygon's corners. Start with the first corner in the lowest array index, end with last corner in the highest index, ie. you must not return to the first corner. Obviously the arrays must match and must have exactly "number of corners" elements. The corners may be traced in either direction (clockwise or counter-clockwise).
fc&& (_INTEGER64)
- Optional the color number used to fill the polygon on a palette based screen, or the _RGB32/_RGBA32 color value on 32-bit screens. Any negative number will disable filling of the polygon, hence make sure your 32-bit colors are defined as unsigned values.
sc&& (_INTEGER64)
- Optional the surrounding borderline color number for drawing on a palette based screen, or the _RGB32/_RGBA32 color value on 32-bit screens. Any negative number will disable drawing of the border, hence make sure your 32-bit colors are defined as unsigned values.