I wrote new functions tonight. I made a big function that automatically writes the PBM,PGM, or PPM formats depending on whether the bits per pixel is 1,2,4,8,3,6,12, or 24. All other values fail. However these allow me to create PNG files the same as I could with the pam format with the pngtopng tool. I also wrote a function that can XOR every pixel in an image with a color.
BBM Update 8-4-2019
My code is still quite disorganized and it’s hard to imagine writing a tool that allows actual users to use it for anything. It’s more like a collection of source files containing functions that I call whenever I’m trying to make something neat. The full alchive of my source code is available here for anyone who wants to get an idea what I’ve been writing and how I make these strange images.