Sick and Wrong

I need something to go from XPM to ANSI graphics.

I must be disturbed.

About Kevin Sonney

Kevin Sonney - who, contrary to popular opinion was NOT raised by wolves - grew up in central North Carolina. He fell into the technology field by accident in 1991, when he gave up the wild and crazy lifestyle of an on-air AM radio DJ to become a mundane technical support monkey. The technology industry has never really recovered from this. Kevin has worked for such names as IBM, Red Hat, webslingerZ, and Lulu Technologies (we won't mention the ones that didn't survive the experience). He currently works as a Linux Administrator for Apptio. In his spare time he rescues stray animals and plays video games with his two sons. His wife, we're sad to say, helps him get past the really hard bits. Kevin is still not very mundane, he just got better at hiding it.
This entry was posted in Uncategorized. Bookmark the permalink.

3 Responses to Sick and Wrong

  1. aklikins says:

    cat foo.xpm| xpmtoppm | ppmtopgm | pgmtopbm | pbmtoascii

    I used to use something similar with a `giftopnm` prepended
    to send gifs over zephyrs.

    I suspect there might be aalib related tools that give
    better results as well.

  2. pbaylies says:

    I hacked something up a while back that went from the raw format of convert (ImageMagick) to HTML font colors over text; I also remember seeing something long ago that went from GIF to ANSI.

    The hard parts are either going to be dithering to the (incredibly) limited standard palette (get something like ImageMagick to do it for you) or figuring out how to use a somewhat extended palette and dithering to that. Other than that, you’re just converting pixel formats to colors to color codes, and optionally picking good characters to use (bonus points for efficient use of foreground and background colors).

    Oh, and, chances are, this has already been done. Maybe you should see if someone has used aalib for this already? That still shouldn’t stop you from doing it yourself…

  3. alchemist says:

    Yeah, I’ve trolled google pretty heavily. I’ll probably burn some cycles on aalib next week, mostly ’cause it looks interesting.

Comments are closed.