Recent Articles



































ASCII art



         


ASCII art, an artistic medium relying primarily on computers for presentation, consists of pictures pieced together from characters (preferably from the 95 printable characters defined by ASCII). They can be created with any text editor, and are often used with free-form languages. Most examples of ASCII art require a non-proportional font (fixed-width font, like on a traditional typewriter) for presentation.

ASCII art was and is used wherever text can be more readily printed or transmitted than graphics. This includes typewriters, teletypes, non-graphic computer terminals, in early computer networking (e.g., BBSes), e-mail, and Usenet news messages.

[Top]

Types and examples of ASCII art

The simplest forms of ASCII Art are combinations of two or three characters for expressing emotion in text. Rotate these examples mentally 90 degrees clockwise for a more recognizable orientation of these emoticons:

 :-) or :) smile  :-( frown  ;-) wink

More complex examples use several lines of text to draw large symbols or more complex figures. Some common examples:

(__) (oo) /-------\/ O / | || /o)\ /H\ * ||----|| \(o/ / \ ~~ ~~ Cow Yin/Yang Person

It is popular to put such art in one's signature block to be included in all one's e-mail and Usenet postings (see also: ASCII cows).


Some types ignore the particular shape of the characters and treat them as more-or-less filled (dithered) boxes:


_a, _yQa. _qTWW( je`?QX: <d+ -3Wm; _qos_s%mWw, a2?????TWW( sd( -?Qm;. .amm; .xmWmc """""` """""""


Another type sometimes seen is creating a word using only one kind of character per letter. For example:


HHHHHH HHHHHH IIIIII HHHH HHHH IIII HHHH HHHH IIII HHHH HHHH IIII HHHHHHHHHHHHHH IIII HHHHHHHHHHHHHH IIII HHHHHHHHHHHHHH IIII HHHH HHHH IIII HHHH HHHH IIII HHHH HHHH IIII HHHHHH HHHHHH IIIIII

One use for ASCII art is to create unique typography, for example:

___ __, ( / ( o _/_ / / __, _ _ `. _ _ , / /_ _/_(_/(_/ /_(/_ (___)/ / /_(_(__/ /_ // (/

The program Figlet (and other programs that support its standard) allow for the design and use of ASCII fonts.

_____ ___ ____ _ _ | ___|_ _/ ___| | ___| |_ | |_ | | | _| |/ _ \ __| | _| | | |_| | | __/ |_ |_| |___\____|_|\___|\__|
[Top]

Methods for generating ASCII art

There exist specialized text editors designed to draw lines, boxes, and filled areas easily. It's straightforward to generate ASCII art algorithmically. Converting a bitmap to ASCII art is a special case of vector quantization. An example of a generated image, beside the original, is given below:

aaaaaa222222SSSSSS2222222SSSS2a22222SSSSSSSS22aaaaaaaa222222SS222aaaZaaZZZZ 2222aaaaS2222222222222222SS2SS22222SSXXXSSXSSXSSSXXXXXSSXSXXXXXX7XSSSSSSS22 2222222aaaZZa222222a222222SS22a22SSX77rrr777X77XXXSSSSSXSSXSSSXXXSXSS22S222 22a2222aaaaaaa22222aaaZZa2aa2aa2222SSSSXXXSSSSXXXXXXSXSXXSSSSXSSSXX7X22SSS2 22222a222222222222aaaZZZZZaaZaaZZZaaaa2a2SSSSSSSXSXXXXXXXXSX7;..,;20X77XXXS 2SSSSSXSSSSSSSSSSSSSS2222aa2222aaaaaa222222SSX7X777XXXX7r: aMMMMBS7XX7XXX SSSSSSXXSXXSSX7:,::i:.:rXSSSSSS22222a2SSXX7XXX77rr;i,  :WMMM@r.,;XSSSSS22 S22a222S2222XirWMMMMMM@a:;XSSXXXSSXXXX77;ii:,,,:...:rX0MMMMZ: ,;XSS2S222222 SSSS22aaa22X,2MMMWWW@@MMM2.:i:,,. ..i7ZB@MMMMMMMMMMMM07 :7SaaaZZaaaaa222 XSXSXXS2S7: rMMZWWWWWWW@MMMB0MMMMMMMMMMMMMMM@WMW@@W@@@@WMMZaZ8888ZZaa2222S2 rrr;77rriXMMMMMWWWWWWWWWWWMMMM@W@M@@@@@@WWWWWBWW@WW@8ZW@MXS0B00088ZZZZaaaa2 ;;iiiii:;ZX;,8MMWWW@@MMMMMMMM@W@WWWWB0@B0WWWWBBWWBWW@MWWMMaSaa222aaaaZaaaa2 ;r;rrrr7;:.. MM@MM@W0B@MMMWMMWWWWWWBWWBWBWWWWWWWWB0ZWMMMM7XXXXX7XSSS2aZaa ii7XSZ2aaaaaa2;,MM@7r7XS8Wi MWB0BWWWWWWWBWWW@WW@MMMM8Xi,;XXSSSSSSSSSSS222 XSSSaZ80BBBBBWB8MM2X2a8MW M0MMWBWWWWWWWWWWWWW@MMMM8SX2aZ88Z8ZZZZaaaaa2SSXX a0008Z22Z800BB08M0 S28MZ MMWWWWW@WWWWWWWW@MM@a;rX2ZZ88ZZZZZZ88ZZaa22SXXX 08a222SS22aZZZZ2BMir7r MMMMBBWWBBBBWWWWWWMMM0,:;rr7XXXXXX777rr77XX7X77X7X 0WWWBB088888ZZ8ZSZMMM8MMMMM@WWWWBBWW@WWWWWMM2,ir7r7r77XXX77rr;;;rr7XXSS2222 SSSaaaZZZaaa22222X;rWMMMMWWWWWWWWWWWWWWWWWMB;r77XXXXS2222SSX77rr;rr7XXX2aZa SSSSSSXXXXX7XXXX777;. XWMMM@WW@@@@WWWWWWMMM22a22222222222SSXX7rrrrrr7XXSSSS 2222SXXXX7XXX7XXXXXX7ri i0M@@MWMMMMM@MMMBZZ0B000000088ZZZZZZZZZaaa22SSSSXS 22aaZZ8Z888808888ZZZZaa2X:MZMMW ..78WMMZrXSSS2222aaaaaZZZZZZZZaZaaa222SS2SS 2SXXSS22aaZ880000BBBBB088S2BWMMXaX7 ;Mii7rr;;;i;;;;;;;rr777r7r7r7rrr7rr77XX 888ZZZZa2SSX77XXSSXSSSSS2SX7 8SrXMr;XX77r77rrrr;;;;;rrrr77r7r7rrrr;rr;i; Z8088ZZZZZZ22SSSSSXX7777rrrXai 7270Mr72aZZZZ888888888ZZZaSSXSXSSSX7r;i::;rS aaaSS2222aaaaaaZaZZZ888888Z88M; .MMrrSSXXXS2aaa2aaaa2S77rrrr777X77XXX2a888Z XXX7X77rrr7XXS222222aZZZ8ZZa7@2: 7M,;;;;iiii::,::,,...,:,.,::i;r;rr7X2ZZa22 XXr;ii::iiii;r777rrr7ri::iir,M,S MMZXS2Zaaa22SXX77777XS222222aaa2SXX777r7XX X77r;rr7XXXSSSSSXS22XrrXSa80Z080, 2Z8aaaZZ880BBWWWWWWWWWWWWWW@WWWWWB08ZZZZ i,:iirrrrr7rrrrr7a:;MMM@WBB0000WMW i8Z22aaa8Z888Z888000BBB88ZZZZ0BBW@MMMMB 822SXXaZa2XX77777Z rMM@8Z880BMM: :XBZaaa22222ZZZZZaa222XXXXXXXXXXXS2aZZ2 8WaSSr77XX2Z0@@@WMMX 7MM@0ZZZ:M2 ;0Z8aSX7r;7XaZaS77r;rXX2aa2SSXXXSSX7r;  ;;7X;:ii.:..7SZ8BWZ;  ;2S77 XB SiX;;rrr;ii;i::,::;r;7X;iii::,,.... , 282X, ..2a8W8Sr.,;a8WMMM@, 2BMW22@. 72a22S22a2aZZ8082;i;:,:iir7XSSXriii ,:SZ,7. i:i .  ;.,.i7rSWMMMr ,2B0iM ,8SSSSXrr7777XXS22a2aZZ8880ZSXX280 . rZMZS8 r:.7 ri ,  ;08Z r8SBZ :;X7SaZ80Z227r:... .,. ,ir7X2 BBZZX7;2;.a8XSSr8000Z@MMMMW0082i ;8WX:70SMSSaa:iii;;rXX7X0MM@BB0Za2S77rr7rX

Another method is to sample the image down to grayscale with less than 8-bit precision, and then assign a character for each value, just as this does.


In the 1970s and early 1980s it was popular to produce a kind of ASCII art that relied on overprinting -- the overall darkness of a particular character space dependent on how many characters, as well as the choice of character, printed in a particular place. Thanks to the increased granularity of tone, photographs were often converted to this type of printout. Even daisy wheel printers could be used. The technique has fallen from popularity since all cheap printers can easily print photographs, and a normal text file (or an e-mail message or Usenet posting) cannot represent overprinted text. However, something similar has emerged to replace it: shaded or colored ASCII art, using ANSI video terminal markup or HTML to add a bit more tone variation.

Animated ASCII art is possible by embedding ANSI video terminal escape sequences for cursor movement into the "picture".

[Top]

Glyph mosaics in Japan

In Japan, the glyph mosaic art form achieves unique development. The so-called "ASCII art" produced in Japan often uses the thousands of extra characters in the JIS or Unicode character sets for more elaborate art. The largest source of recent "JIS Art" is the 2ch BBS, and characters and stories in these "JIS Arts" are gaining popularity and recognition with emergence of this BBS. Cultural similarity with Manga (Japanese comic) can be observed. A simple example of Japanese style of the Ascii art is "orz" and represents a man on all four kneeling in an expression of the despair. "o" is the head, "r" is arms and shoulders, and "z" is the back and bent legs.

[Top]

Placing ASCII art in HTML pages

ASCII artwork embedded in an HTML document must be placed within the <pre>...</pre> preformatted text element to ensure that arrangement of the characters will display properly with monospace fonts (aka non-proportional fonts).

It allows navigational maps, with some or every "pixel" (i.e. character) being a link. Some consecutive characters can also be a single link. However, is does not seem possible to have a multi-line area being a single link, like in image maps using the <area> tag (e.g. ). Of course some character sequences on different lines can link to the target, but if a link highlights when the cursor is at it, not the whole area is highlighted.

Example, with both the city outline and the label clickable:

x xxx Leiden x
xx xxxx The Hague xxx
xx xxxxx Rotterdam xxxx
[Top]

See also

[Top]

ASCII art groups

ASCII art groups are defined as organized bodies of people dedicated to the purpose of creating ASCII text based artwork.







  View Live Article   This article is from Wikipedia. All text is available under the terms of the GNU Free Documentation License