Mindhue Studio

Printmaking, conceptual and installation art

Animated Twitter Graphic (.atg?)

Another stab at using Twitter as a data pipe, this time I’ve decided to send an animated graphic as CGA-encoded color frames. This will be similar to an animated .gif file, and I’ve prepared one of those to show what the final image will look like, but this will be completely text-encoded for Twitter.

I’ve also decided that this process needs some machine-readable codes, so if you created a Twitter Graphic Decoder (TwGD) that monitored a Twitter feed it would automatically understand that a graphic was coming its way. Since Twitter itself already uses the hashtag (#) and the at sign (@) to encode Twitter-related information, I’ve decided to co-opt another rarely-used ASCII symbol for my own purposes. So, my Twitter Graphic Tag (TGT) will be the grave-accent, or (`).

So my tweets should set the format and the image payload for the TwGD as a matter of course. With that in mind, I need to have a given area of the tweet for such encoding, so let’s use the convention I set before, maybe using 8-15 characters for this information. To make it easier on the TGD, let’s use that space as a header instead of a footer like I did before. With all this in mind, here’s the first frame of my ATG:


The header convention spelled out here is this:

`CGA is the color encoding scheme, in this case, the hexadecimal CGA color palette. This will be a three-digit alphanumeric string.

`11×11 is the pixel dimensions in WWxHH, always two digits for each dimension with an (x) in-between. We really can’t encode anything larger than 30 pixels in a Tweet anyway, but the extra overhead is nice.

`80 will be the hexadecimal sequence number of the frame in an animation, starting with 00. For styles of animation, let’s define the first 128 frames (00 – 7F) as encoding static images and the second 128 frames (80-FF) as looping frames. This way we can keep two digits for animation encoding, include a looping option,  and still have around 100 frames to play with.

`{ is a code that makes it explicit that the image data payload is next. It’s not entirely necessary to encode this, but since I have the text space available, I figured it would be nice to have a strong signifier for the payload. The ({) works nicely.

With all that, I still have four text spaces to play with. It would be nice to have a unique identifier for the image so the TwGD can properly assemble the animation, kinda like the ASCII squib used for bit.ly links and such. Of course, this is limiting the Animated Twitter Graphic size to 121 pixels, or a max of about 11×11 or 12×10 or thereabouts. I think that’s okay. Animation always adds something extra that makes the image more human-readable. If there’s no animation-frame ID, the TwGD will assume it’s a static image and those extra seven spaces can be used for payload. So let’s redefine the animation frame code to be a four-digit ASCII ID with a two-digit frame count:

`XXXX00 will be the image ID number and frame sequence number in an animation.

So our new tweet will be:


Which will be joined by its siblings






Which, when assembled by the still-vaporware TwGD, will look like this: