Friday, March 14th, 2008

Asciify: ASCII art library

Category: Fun, Library

<>p>

Asciify is a new library that draws ASCII art for you, so it had “Friday” written all over it:

There are trends on the web (as in real world) that last days or weeks and there are things that became a classic form of expression of the geek culture and are still interesting to explore after 20+ years.

Ascii Art is one of these things. If you don’t know what ascii art is you’re probably reading the wrong blog, however for the one or two that doesn’t know about it, here you can learn more about it: Ascii art on wikipedia.

I always had in mind the idea to create an actionscript class to render ascii art from pictures and now with as3 this is going to be possible at decent speed.

My class is called Asciify and it can actually “ascii-fy” every DisplayObject instance on the display list.

It is simple to use too:

javascript
< view plain text >
  1. var asciifyInstance:Asciify=new Asciify(picture, textFormat, 16);
  2. addChild(asciifyInstance);

Takes me back to my insanely cheesy .sig files from many years ago:

         \|// 
         (o o)
+----oOOo-(_)-oOOo--------------------------------------------------+
|   dionXalmaer.com   |               FREE TIBET *                  |
| www.almaer.com/dion | * with any tibet of equal or greater value  |
+-------------------------------------------------------------------+

Related Content:

Posted by Dion Almaer at 9:43 am
10 Comments

++++-
4 rating from 42 votes

10 Comments »

Comments feed TrackBack URI

Do you really think that “sig” needed to be jested about? There are riots right, as we speak, where people are being beaten and possibly killed. I’m not trying to get on a soap box but trivializing the Tibet situation probably isn’t very conscientious.

As for the lib… Cool!

Comment by AndrewHerron — March 14, 2008

http://www.cafepress.com/buy/*+with+any+tibet+of+equal+or+greater+value+/-/pd_13630063?CMP=KNC-F-ALL

Comment by PHPAugusta — March 14, 2008

On a related note, there’s a cool Matrix ASCII animated sequence (elements shown/hidden via Javascript) here.

Comment by Scott Schiller — March 14, 2008

Free Tibet! ^_^

I think he was observing the need for a free tibet, while being humorous. Humor is one of the most persuasive argumentative techniques. :)

Comment by Carbon43 — March 14, 2008

Can anyone think of a good reason why this couldn’t be used as part of a simple, automated, low bandwidth Captcha technology:
1 – Generate random text on the server, save text and identifier.
2 – Convert text to an image (using ImageMagick or similar).
3 – Convert image to ascii art (using asciify).
4 – Send ascii art to user, with hidden identifier for comparison upon submission.

I can see two problems:
1 – Reverse engineering back to real text may be too easy, although there will be information loss when converting initially. Extra difficulty could be created by adding an actual image behind the text before asciifying.
2 – Ascii art representing actual text may be difficult for a human to decypher , especially with an image behind it, so the ascii art may need to be quite large on the page.

Comment by tetburr — March 14, 2008

And here’s a version built on top of web standards like HTML, CSS and JavaScript;
http://ajaxwidgets.com/Blogs/system_rss/ascii_art_generator_ajaxified.bb
And the actual generator;
http://ajaxwidgets.com/Ascii-Art/AsciiArt.aspx

Comment by polterguy — March 15, 2008

And here’s one using js and the canvas tag to turn images into ascii art: http://www.nihilogic.dk/labs/jsascii/

Comment by CupBoy — March 15, 2008

Bad “signature”, don’t make fun with the serious TIBET situation!

Anyway, the library is so cool.

Comment by bluepower — March 16, 2008

Nice find… I remember spending hours working on little pieces of Ascii art many years ago.

Comment by milancole — March 17, 2008

To see the entire Star Wars movie in Ascii Art:

telnet towel.blinkenlights.nl

!!

Comment by ArthurBlake — March 18, 2008

Leave a comment

You must be logged in to post a comment.