Paintutils (API)
From ComputerCraft Wiki
Paintutils is a default API for advanced systems which can draw pixels and lines, load and draw image files. Use colors API for easier color manipulation.
Paintutils (API) | ||
---|---|---|
Function | Return values | Description |
paintutils.loadImage(string path) | table image | Loads and returns an image object from path. |
paintutils.drawImage(table image, number x, number y) | nil | Draws an image at (x, y) where image is an image object. |
paintutils.drawPixel(number x, number y [, number color]) | nil | Draws a pixel at (x, y). If color specified draws it in that color. |
paintutils.drawLine(number startX, number startY, number endX, number endY [, number color]) | nil | Draws a line from (startX, startY) to (endX, endY). If color specified draws it in that color. |