Extracted from Pike v7.6 release 61 at 2005-12-30.
pike.ida.liu.se
[Top]
Image
Image.Image

Method Image.Image()->polyfill()


Method polyfill

object polyfill(array(int|float) ... curve)

Description

fills an area with the current color

Parameter curve

curve(s), ({x1,y1,x2,y2,...,xn,yn}), automatically closed.

If any given curve is inside another, it will make a hole.

Image.Image(100,100)->setcolor(255,0,0,128)->
  polyfill( ({ 20,20, 80,20, 80,80 }) );

Returns

the current object

Note

Lines in the polygon may not be crossed without the crossing coordinate specified in both lines.

Bugs

Inverted lines reported on Intel and Alpha processors.

See also

setcolor