Skip to content
awesome-llama edited this page Feb 25, 2024 · 9 revisions

Welcome to the full documentation for TextImage!

Motivations

The image format outlined here was necessitated by the lack of any decent way to store bitmap image data in Scratch. Scratch is limiting in that binary data can not be stored, only strings, booleans, and double floats. Binary data represented using base 64 or hexadecimal numbers have been demonstrated but are suboptimal (there are many unused characters) and use of common binary image formats like BMP, PNG, and JPEG are difficult to read/write using Scratch's limited feature set. Instead, what is more common in Scratch is use of very simple and usually custom-made uncompressed formats, for example, hexadecimal numbers for each pixel concatenated together. Many of these formats lack essential features necessary for adoption and standardisation.

Format Outline

  • Supports an arbitrary number of colour channels including lossless 8-bits per channel RGB bitmap images and lossless 8-bits per channel generic (e.g. for alpha).
  • Uses printable ASCII characters only, no spaces and no newlines.
  • Simple enough to implement in Scratch (minimising the number of blocks and variables), enabling it to be more easily used in projects.
  • Offers significantly smaller file sizes compared to pre-existing Scratch methods, and in some cases even better than common image formats like PNG.

Links