Skip to content

Instantly share code, notes, and snippets.

@andyherbert
andyherbert / proposal.md
Last active February 11, 2025 03:26
ANSi Art File proposal

This is not meant to be a hard proposal for a new file format, it's just what I've occasionally thought about and decided to put out into the world to crystalize my own thinking and invite criticism.

Why a new ANSi Art file format?

.ANS files have limitations:

  • I can only use certain fonts, these are limited to IBM Codepages, Amiga fonts, and a few others. The XBin format allows a user-defined font to be used, but these can only be 8 pixels wide and up to 32 pixels high, what if I wanted to use a font only 4 pixels wide and 8 pixels high? Maybe I want to create my own font and give it a name that people can see.
  • SAUCE records are attached to the end of the file - this is problematic when streaming data, if you are defining how something should be displayed then you need to specify this before sending the data you're displaying, not afterwards.
  • SAUCE records are also fairly wasteful and contain lots of unused or padded bytes, this is especially true for records with comments, and strings have to be enc