Can I save an ImageData or Image into a new file with löve2d in lua?

768 Views Asked by At

I need to know if it's possible to save an "ImageData" (or something like that) into a new file in Lua with Löve2D, and how ? If I can't, how can I do that ?

thank you in advance !

1

There are 1 best solutions below

1
On BEST ANSWER

Love2D ImagaData objects can be encoded via the "Encode" function, in Love 0.10.0

img:encode(type, filename)

in 0.8.0 and later, Type was not required.