Blinkenlights Markup Language
We are documenting the file format here so that whoever is interested in producing this format directly can do that. Knowledge of this information is not necessary to use our tools dealing with that format. Knowledge of XML is however helpful.
The DTD (Document Type Definition) can be found here (if you don't know what a DTD is good for you can safely ignore it): http://www.blinkenlights.de/dtd/bml.dtd
The name of a Blinkenlights Markup Language file should end in ".bml" but does not necessarily has to do so.
Each Blinkenlights Movie starts with the document element <blm>. It (optionally) contains a <header> element and one or more <frame> elements. <header> exclusively contains meta information that is not required for playback of the animation. <frame> elements contain the actual pixel information.
The document element states height and width, as well as colour depth (bits) and number of colours (channels). The Arcade installation always sets "channels" to 1 (because of its greyscale nature). The value of "bits" can vary: 1 (monochrome), 2-8 (4,8,16,32,64,128,256 greyscales).
Please note: the toplevel element is really called <blm> and NOT <bml>. I know you might think this is illogical and you are right. Instead the name refers to our original Non-XML file format (BLM). In retrospect, this might have been a bad idea. But we thought it was funny back then :)
Attributes of <blm>
|width||Width of the matrix in pixels|
|height||Height of the matrix in pixels|
|bits||Color depth in bits (1 = monochrome)|
|channels||Number of colour channels. For Arcade this is always 1 (brightness only). For RGB pictures the value is 3 (red, green and blue).|
Elements in <header>
|title||The title of the animation|
|description||Short description of the animation in one or two sentences (optional)|
|creator||Software that was used to create the animation file (optional)|
|author||Name of the author (optional)|
|e-mail address of the author (optional)|
|url||Author/animation related web page (optional)|
Elements in <frame>
Each frames contains as much
Structure of row data
Each single row describes the pixel colour values in hexadecimal notation. If the colour depth is between 1 and 4, one hexadecimal digit is used per colour value (0-f). If the colour depth is between 5 and 8, two hexadecimal digits are used per colour value (00-ff).
The is one value for each pixel, one after the other. In an RGB picture with channels="3" there are three colour values in sequence.
<?xml version="1.0" encoding="utf-8"?>
<blm width="26" height="20" bits="4" channels="1">
<description>Un portrait du grand maître du suspense</description>
<author>J. Random Hacker</author>