tim0s / ansi2gif Goto Github PK
View Code? Open in Web Editor NEWThis project forked from deater/ansi2gif
convert ASCII/ANSI art to a graphics files
This project forked from deater/ansi2gif
convert ASCII/ANSI art to a graphics files
***************** ansi2gif version 0.10.0 *************** ***************** *************** by Vince Weaver vince _at_ deater.net http://www.deater.net/weave/ github.com/deater/ansi2gif.git Requirements: Designed for Linux, but any platform with gcc will probably work. ------------------------------------------------------------------------- HISTORY ------------------------------------------------------------------------- I was thinking of extending my "fontprint" program to make it work better with gif output. But then I thought, if I am going to do that, why not make it so it can print colors? I went a bit overboard, one thing led to another, and here is ansi2gif. I decided to leave "fontprint" behind because it does its job well. ansi2gif is specialized, and while it shares some code, it is a completely different program. The included example_ansis are ones I drew myself back in the period of 1992-1996 or so. My friends Jason Grimm and John Clemens ran a WWIV BBS called "Utopia". The BBS no longer exists, please do not try to call. I made about 100 different ANSIs, mostly animations. It was a desire to see them again that was the real impetus behind this project. ------------------------------------------------------------------------- HOW IT WORKS ------------------------------------------------------------------------- I built an "ANSI" escape-code interpreter using a reference someone sent me once while I was working on linux_logo. I used Tom Boutell's [http://www.boutell.com] excellent "gd" gif library to make the basis gifs. I used a slightly modified version of the "whirlgif" utility to do the animations. [http://www.danbbs.dk/~dino/whirlgif] A temporary file is created in /tmp/ansi2gif_%i.gif [where %i is the pid of ansi2gif] in which all the transitory gifs for an animation are made. (NOTE TO SELF.. INSECURE. FIX THIS) The fonts used are standard "vga" fonts. Basically they are just 4k files holding a set of 256x8x16 data, where there are 256 characters, 16 lines, and then each line is reperesented as a 8bit character. The 8 bit character, in binary, tells what bits to turn on and off to make an 8x16 font. The EPS output works a bit differently. It uses the "pcfont" Postscript font, and does some tricks to try to keep the size of the resulting file as small as possible. ------------------------------------------------------------------------ INSTALLING ------------------------------------------------------------------------ Get the "gd" utility from http://www.libgd.org/ (Or else install the version that comes with your operating system). Install it. Now install ansi2gif Uncompress the file tar -xzvf ansi2gif-0.10.0.tar.gz Enter the created directory cd ansi2gif-0.10.0 The Makefile should be OK. If you have "gd" installed in a non-standard directory, you might have to edit the makefile to tell it where you have the gd libraries installed. Compile the program make Copy the program to where binaries are kept. make install That's it! It should be all installed! --------------------------------------------------------------------- USAGE --------------------------------------------------------------------- ansi2gif [--animate] [--blink] [--eps] [--font fontfile] [--gif] [--help] [--png] [--version] [--timedelay T] [--xsize X] [--ysize Y] input_file output_file --animate : Create an animated gif if an animated ansi --blink : Create an animated gif enabling blinking --eps : output an EPS file --font fontfile : Use vgafont "filename" to create gif --gif : output a GIF file --help : show this help --png : output a PNG file --timedelay T : Delay T 100ths of seconds between each displayed character in animate mode. --version : Print version information --xsize X : Make the output X characters wide --ysize Y : Make the output Y characters long. use "auto" to figure out on the fly. Instead of the long option, a single dash and the first letter of the option may be substituted. That is, "-a" instead of "--animate" ------------------------------------------------------------------------ WHERE TO DOWNLOAD ------------------------------------------------------------------------ http://www.deater.net/weave/vmwprod/ansi2gif/ http://metalab.unc.edu/pub/linux/apps/graphics/convert ------------------------------------------------------------------------ NON-LINUX ARCHITECTURES ------------------------------------------------------------------------ Solaris: ansi2gif has been reported to work fine under Solaris, however you need to find gnu "getopt()" code. [You can steal it from the gdb package]. [thanks to arthurj _at_ uccs.jpl.nasa.gov] If you have reports of ansi2gif working on other architectures, feel free to e-mail me about them. ------------------------------------------------------------------------- THANKS ------------------------------------------------------------------------- Thanks to Tom Boutell, author of the "gd" library Thanks to the various whirlgif authors http://www.danbbs.dk/~dino/whirlgif/ Also special thanks to my lovely wife. ------- Vince Weaver (6 January 2014) vince _at_ deater.net
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.