Png Bot is an image bot which uses the png transparency layer to effectively hide one image in another depending on the background color of the viewer. I got the idea from a tweet by user @taki_bump, but the account has since been deleted (or renamed?). Here is the original image that inspired me to try to make a bot:
The python based bot uses Image Magick to do the image modifications:
- The two images are converted to grayscale and 8×8 ordered dither is added.
- The Darker image has the transparency layer set to white.
- The Lighter image has the transparency layer set to black.
- The two images are composited.
This works because Twitter (as well as many other sites/ apps) default to a light/ white background in preview and a darker background when you view the full sized image. If you save one of the resulting images on an iPhone you can also see the effect between preview/ full size view. It used to work better on Twitter before they changed the background colors.
Note: if you’re using “Night Mode” the effect doesn’t work at all..
— Png Bot (@pngbot) October 4, 2016
Launched: May, 2015
Source Code: github.com/vgan/pngbot