Blinkenlights Markup Language

Blinkenlights Markup Language

thinkpad The Blinkenlights Markup Language is the file format in which ArcadePaint saves it pictures and animations. It is a XML-based format. 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 ArcadePaint. 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

Document Structure

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).

Attributes of <blm>

widthWidth of the matrix in pixels
heightHeight of the matrix in pixels
bitsColor depth in bits (1 = monochrome)
channelsNumber 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>

titleThe title of the animation
descriptionShort description of the animation in one or two sentences (optional)
creatorSoftware that was used to create the animation file (optional)
authorName of the author (optional)
emaile-mail address of the author (optional)
urlAuthor/animation related web page (optional)

Elements in <frame>

Each frames contains as much <row> elements, as specified by the height attribute. The attribute duration the specifies the time the picture is visible in milliseconds.

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.

Example

<?xml version="1.0" encoding="utf-8"?>

<blm width="26" height="20" bits="4" channels="1">

    <header>

        <title>Alfred Hitchcock</title>

        <description>Un portrait du grand maître du suspense</description>

        <creator>ArcadePaint</creator>

        <author>J. Random Hacker</author>

        <email>my@email.com</email>

        <url>http://my.home.page/</url>

    </header>

    <frame duration="200">

        <row>00000001369ceec95100000000</row>

        <row>0000127acdeffffffe94000000</row>

        <row>0015569bcdeeeeffffffb50000</row>

        <row>01421465779eeeedccdefeb100</row>

        <row>0110026bdd77deddeeedeed300</row>

        <row>000011136aa5ced979bcdcc200</row>

        <row>0000688acb65bddeddeefca100</row>

        <row>000028abca11468deedddb8200</row>

        <row>0000247bc30248acddcccbc700</row>

        <row>0000025ba668abcbcdcbbad600</row>

        <row>00000069525779baacca99c400</row>

        <row>0000002850013557baaa966100</row>

        <row>00000003212469baaa98710000</row>

        <row>00000000000001354368300000</row>

        <row>00000000000001377567100000</row>

        <row>000010000000169b98ae400000</row>

        <row>00001100000002699dff700000</row>

        <row>000001225887203affffb10000</row>

        <row>0000469bdee60012afffb10000</row>

        <row>00003cadfffa118eceef710000</row>

    </frame>

</blm>

	

File Names

The name of a Blinkenlights Markup Language file should end in ".bml".