As I only run Linux on my computer, I had to do some manual work to get it running.
At first I wrote a little tool, to convert tiff images to the art.lebedev format of these sys-files. Here's the source. You'll need libtiff and libtiff-dev to compile and run it. argv[1] is the input file (must be tiff, 48x48), argv[2] is the resulting sys-file.
 |  |  |
 | Code: #include <tiffio.h>
int main(int argc, char* argv[]) { TIFF* bild;
uint32 raster[48*48]; uint16 res[48*48];
bild = TIFFOpen(argv[1], "r"); TIFFReadRGBAImage(bild, 48, 48, raster, 0);
for (int y = 0; y < 48; y++) { for (int x = 0; x < 48; x++) { res[x+48*y] = ((TIFFGetR(raster[x+48*y]) & 0xF8) | (TIFFGetG(raster[x+48*y]) >> 5)) | (((TIFFGetB(raster[x+48*y]) >> 3) | ((TIFFGetG(raster[x+48*y]) >> 2) & 0x07)) << 8); } }
FILE* f; f = fopen(argv[2], "w"); for (int y = 47; y >= 0; y--) { for (int x = 0; x < 48; x++) { fwrite(&(res[x+48*y]), sizeof(uint16), 1, f); } } fclose(f); return 0; }
|  |
 |  |  |
I didn't do much testing or error handling, but it basically works for me. Will probably update it soon.
Now you can create your key-images with your favourite image manipulation application.
To activate them, I just wrote some little shell scripts, that look like this:
The
sync at the end is important to commit the changes. Otherwise they will be kept in the fs-cache and it will take a while until the changes take effect.
To generate text on the fly, you can use imagemagick:
This will generate a little tiff file containing the text 'wtf?'. Now copy it into your keyboard:
Check the docs of imagemagick for adding more cool effects.
Some cool dynamic stuff:
This will put the current time into your spacebar. I'm using cron, to update it every minute.
Any more Linux users out there? Let me know, how you handle your Optimus.
Questions or problems with my scripts? Feel free to ask.