Skip to main content

An ASCII art and text cinematic storyboard/demo library

Project description

Asciimatics is a package to help people create simple ASCII animations using curses. It is licensed under the Apache Software Foundation License 2.0.

It originated from some work that I did on PiConga to create a retro text credits roll for the project. This worked so well, I re-used it for another project. At that point I felt it might be fun to share with others.

Why?

Why not? It brings a little joy to anyone who was programming in the 80s…

Installation

To install asciimatics, simply:

$ pip install asciimatics

How to use it?

Create a curses window, create a Screen, put together a Scene using some Effects and then get the Screen to play it.

import curses
from asciimatics.effects import Cycle, Stars
from asciimatics.renderers import FigletText
from asciimatics.scene import Scene
from asciimatics.screen import Screen

def demo(win):
    screen = Screen(win)
    effects = [
        Cycle(
            screen,
            FigletText("ASCIIMATICS", font='big'),
            screen.height / 2 - 8),
        Cycle(
            screen,
            FigletText("ROCKS!", font='big'),
            screen.height / 2 + 3),
        Stars(screen, 200)
    ]
    screen.play([Scene(effects, 500)])

curses.wrapper(demo)

And you should see something like this:

asciicast

Documentation

Documentation is available at http://asciimatics.readthedocs.org/en/latest/

More Examples

More examples of what you can do are available in the project samples directory, hosted on GitHub. See https://github.com/peterbrittain/asciimatics/tree/master/samples.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

asciimatics-0.3.0.tar.gz (13.6 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page