Name
lmiencoder - encode bitmap images to lossless matrix images (.lmi)
Download
MacOS (universal 64-bit)
Synopsis
lmiencoder -i FILE (options)
Description
lmiencoder encodes bitmap images to lossless matrix images and outputs them as .lmi files or c-style arrays.
lmiencoder can load the most widespread image bitmap formats: PNG, JPEG, GIF, PNG, BMP etc. The default pixel format is argb8888 (note: many arduino/esp8266 etc libraries uses rgb565).
Options
-o
Name of the output file. If none is specified the input file's name is used with the .lmi extension
-a
Appends the input image data to an existing lmi-file when creating animations. If no output file is specified it will create a new file named after the input file
-r
Use 16-bit rgb565 color format. If omitted the 32-bit argb8888 format is used
-c
Prints the image data without the lmi-header as a c-style array. Only available in conjunction with the -r switch
-f (fps)
Set the frame rate. Specify this for the first frame when creating animations -h Display help message and exit.
-v Be verbose
Examples
Create a lossless matrix image named hello.lmi using 32-bits to represent a full palette including alpha channel
lmiencode -i hello.jpg
Create a lossless matrix image named bar.lmi using a 16-bits colorspace
lmiencode -i foo.jpg -r -o bar.lmi
Create a C header file named logo.h with a c-style array of uint16_t representation of the input image. The array variable is named logo after the input file
lmiencode -i logo.png -r -c > logo.h
Create an animation with 4 frames at 10 fps and 16-bit colorspace
lmiencode -i frame0.jpg -r -f 10 -o animation.lmi
lmiencode -i frame1.jpg -r -a -o animation.lmi
lmiencode -i frame2.jpg -r -a -o animation.lmi
lmiencode -i frame3.jpg -r -a -o animation.lmi