I've been pondering about using Unicode Character 'LOWER HALF BLOCK' to double the pixel resolution on a terminal, such that the background and foreground colors of that block are "two pixels" in one.
So I searched the web on how to get pixel information from ImageMagick, which I then feed to a perl script to join together (so two pixel lines make one ascii line).
I then tried to convert the truetype colors to RGB256, and the result was rather bland when using real pictures, but okayish with drawings. Then I added file compression by checking the previous pixel, and if it's the same color, it skips printing the ansi escape codes.
Improvements can be made by using
quadrants to curve-fit better, but that would require to antialias with the image before compressing it down with ImageMagick. That would fix the jaggedness of the chin in the sample image. But within that block, we can still only use 2 colors. (a limitation familiar to C64 graphic artists)
$ ./image2ascii.pl ~/Picture/socialmedia/12399.jpg 12399.ascii 0 1
Edit: Added the code to GitHub:
Convert an image, using ImageMagick to an ANSI colour image (Linux only) - GitHub - FBnil/image2ascii: Convert an image, using ImageMagick to an ANSI colour image (Linux only)
github.com