Posted by fatius at November 22nd, 2006

I wrote some image libraries to handle the image loading for my window manager. There were lots of goals, but mostly, I wanted people to be able to compile the window manager without any other dependencies outside of X11. I also wanted to include super fast manipulation and display of images. For example, I wanted to make it so that you could create a close button image for the window manager and the window manager would be able to invert it while it was being pressed so that you didn’t have to make two images. I never made it that far, but I did some pretty nifty stuff along the way.

The goal of the library was to support most common image formats. At the moment it can import XPM images and SIMG (it’s own format). It can convert between the two without any external libraries at all. With X11, it can display both of those types of images on the screen.

In creating these libraries, I also created a very basic set of GUI widgets. It included buttons, very basic text display/input, and the progress bar seen below on the loaded images.

These libraries were initially developed on Linux, but they work fine on a Mac. With some minor modifications it would work on a Windows system with X11.

This first image is simple; I wanted to show the regular image and some modified RGB images based on it. I’m sure you can see what I was going for here.
warhol.png

The next test didn’t work as well, but I was clearly getting there. I was trying to create a filter that made images look like they’d look if they were printed in comic books or in cheap newsprint.
comic.png

And finally, I wanted the library to be able to quickly load images that would be needed for the window manager to function. Here is one of those.

slap.png