1. About a2png
  2. News
  3. Download
  4. Source code
  5. Example
  6. Author
  7. Links
  8. Screenshots


This software is licensed under the CC-GNU GPL.
Valid XHTML 1.0 Strict

About a2png

a2png is a UNIX program that converts plain text into PNG images.

a2png is written in C and distributed under the GNU General Public License v2.


Date Description
2006-10-09 You can now browse the a2png svn repository
2006-10-06 a2png-0.1.5 released, option --html-input now auto-detects plain text files
2006-09-26 a2png-0.1.4 released, now handles carriage returns
2006-09-26 a2png-0.1.3 released, optimized for a bit faster performance
2006-09-22 a2png-0.1.2 released, contains support for the GD library


You can download the a2png source code from

You need either the GD library or Cairo graphics library to build a2png. On Mac OS x, you can do a sudo port install cairo (or something like that) to get cairo graphics.

Source code

You can browse the subversion repository for a2png.


The last image below was generated with the following command:
$ head -80 a2png.c | tail -40 | a2png --crop - --font-size=0.015 \
--size=800x800 -v --overwrite

output format: PNG ARGB32
output dimension: 800x800 pixels
reading standard input
cropping output image to 456x480 pixels
writing stdin.png


Copyright ©2006 Christian Stigen Larsen
Distributed under the GNU General Public License v2.



Bender, converted to ASCII by jp2a and back to PNG with a2png
Output from jp2a, converted back into an image

Example text to image conversion by a2png
Part of the source code for a2png