A language built for fun
This project is maintained by cometlang
inherits Object
The coordinate system for the images starts with 0,0 at the bottom-left and ends with (width-1),(height-1) at the top-right. It is always in 24-bit colour, 8 bits per channel and does not currently support an alpha channel. Jpegs are written at a constant 90 quality.
PNG
JPEG
BMP
Image(width, height)
creates an image of width x height pixelsset_pixel(x, y, r, g, b)
sets the pixel colour at coordinates x, y to the colour values (0-255) of r,g,bwrite_to_file(filename, format)
writes the image to the filename, in the given format (a value of the IMAGE_FORMAT
enum)width()
gets the number of pixels in the x axis of the imageheight()
gets the number of pixels in the y axis of the imageread(filename)
reads the image