A tool to convert PNG image data into Xlib-compatible cardinal ARGB buffer.
It basically lets you embed raw image resources into your X11 programs.
Can be used as the data parameter to XChangeProperty()
. See the example program for reference.
Requires libpng-dev
to compile, libpng
to work.
make clean all
sudo make install
png2argb image16.png image32.png > buffer.h
unsigned long buffer[] = {
16, 16,
0, 0, 0, 0, [...],
32, 32,
0, 0, 0, 0, 0, 0, 0, 0, [...],
};