| Scilab Reference Manual | 
|---|
xfpolys — fill a set of polygons
xfpolys(xpols,ypols,[fill])
| xpols,ypols | : matrices of the same size (p,n) (points of the polygons). | 
| fill | : vector of size n. | 
xfpolys fills a set of polygons of the same size defined by the two matrices xpols and ypols. The coordinates of each polygon are stored in a column of xpols and ypols.
The pattern for filling polygon number i is given by fill(i):
| - | if fill(i)<0, the polygon is filled with pattern id -fill(i). | 
| - | if fill(i)=0, the polygon is drawn with the current dash style (or current color). | 
| - | if fill(i)>0, the polygon is filled with pattern id fill(i). Then its contour is drawn with the current dash (or color) and closed if necessary. | 
plot2d(0,0,[-1],"012"," ",[0,-10,210,40])
x1=[0,10,20,30,20,10,0]';
y1=[15,30,30,15,0,0,15]';
xpols=[x1 x1 x1 x1]; xpols=xpols+[0,60,120,180].*.ones(x1);
ypols=[y1 y1 y1 y1];
// setting the current dash (or line color)
xset("color",5)
xfpolys(xpols,ypols,[-1,0,1,2])
xset("default")
 
  J.Ph.C.
| << xfarc | xfpoly >> |