If I'm writing some low level code (say, in C), at times I will want a quick way to
quickly output an image file, and sometimes I'm too lazy to bring in a graphics library that can write actual .png files.
I wrote a little program that converts ".simple" images (which are a list of R,G,B bytes) into 24 bit .bmp files.
So, your program simply writes a tiny header and three bytes per pixel, and simpletobmp.exe turns this into a .bmp.
Here is an example:
Or, from Python,
(This one draws a gradient in red and green. Change the fputc lines in the inner loop to draw the image you want. A common usage is to set up a 2d array of pixels, draw the picture into that array, and then output everything to a file).
Now, one can run
simpletobmp.exe o test.simple test.bmp
to get the image.
This is similar to how in Linux, one can write a .ppm file, which is, literally, a brief header and list of rgb values.
It's funny, the .ppm format can even accept pixel information in human-readable ascii digits!