fillPolygon(pixels, points, color) fills a polygon in a picture painted in code: a ramp, a slope of ground, a roof, a range of hills. A pixel is painted when its middle is inside the outline or on it, so the edge is stepped like pixel art, a ramp up and a ramp down are mirror images, and two polygons that share a side leave no gap between them.
The picture is shown as any other (createPixelTexture), and painted again whenever it changes, then sent with updatePixelTexture.
Click the preview first so it hears the keyboard. Space paints new hills.