Functions

Image:array() Get the internal Array data
Image:fromarray(array) Set the internal data with an Array
Image:load(filename) Load an image file
Image:load_threaded(filename) Load an image file in its own thread
Image:loading() Check to see if the the image file has loaded
Image:save(filename) Save the internal image data to a file

Functions

Image:array()

Get the internal Array data

Return:

  • The array
Image:fromarray(array)

Set the internal data with an Array

Parameters:

array The array
Image:load(filename)

Load an image file

Parameters:

filename The image filename
Image:load_threaded(filename)

load_threaded should be used with care. Only try to access the internal matrix after the image file is fully loaded by using Image.loaded.

Parameters:

filename The image filename

See Also:

Image:loading()

Check to see if the the image file has loaded

Return:

  • True/False for whether the file has loaded
Image:save(filename)

Supported formats for saving are JPEG (.jpg), JPEG2000 (.jp2), PNG (.png), TIFF (.tif), BMP (.bmp), and GIF (.gif)

Parameters:

filename The filename to use when saving the internal image data