Skip to main content

YouTube video playback in terminal as ASCII

Project description

yt2term

yt2term streams YouTube videos (or direct video links) as real-time ASCII art directly inside your terminal.

Entirely impractical - Weirdly meaningful


example frame


Features

  • Real-time video → ASCII conversion
  • ~30 FPS rendering loop
  • Optional color rendering
  • Adjustable output width
  • Optional audio playback via ffplay
  • Automatic FFmpeg detection

Installation

Development install (recommended)

git clone https://github.com/<your-username>/yt2term.git
cd yt2term

pip install -e .

This installs the CLI command:

yt2term

Standard install

pip install .

Use this if you just want a normal installed package.


Python Version

  • Requires Python ≥ 3.10
  • Tested on Python 3.10+ / 3.12

Dependencies

Installed automatically via pyproject.toml:

  • opencv-python
  • yt-dlp
  • pillow
  • asciifyy

Audio Support

Audio playback uses ffplay from FFmpeg.

Audio is disabled by default.

Enable it with:

yt2term <link> --audio

If FFmpeg is missing, the application will:

  1. Detect it automatically
  2. Explain what is missing
  3. Prompt installation
  4. Attempt installation using the system package manager

No digging through random forum posts from 2014 required.


Usage

Basic playback

yt2term <youtube-or-video-url>

Enable audio

yt2term <url> --audio

Disable color output

yt2term <url> --no-color

Set ASCII width

yt2term <url> --width 120

Combined options

yt2term <url> --audio --width 100 --no-color

Notes

  • Uses yt-dlp to resolve streaming URLs
  • Requires an internet connection during playback
  • Performance depends heavily on terminal rendering speed
  • Audio/video sync is approximate
  • Designed for fun, experimentation, and terminal abuse

Exit

Press Ctrl+C to stop playback and return to reality.


Project Structure

yt2term/
├── src/
│   └── yt2term/
│       ├── main.py
│       ├── cli.py
│       ├── video.py
│       ├── audio.py
│       ├── render.py

License

MIT

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

yt2term-0.1.0.tar.gz (5.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

yt2term-0.1.0-py3-none-any.whl (6.3 kB view details)

Uploaded Python 3

File details

Details for the file yt2term-0.1.0.tar.gz.

File metadata

  • Download URL: yt2term-0.1.0.tar.gz
  • Upload date:
  • Size: 5.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.11

File hashes

Hashes for yt2term-0.1.0.tar.gz
Algorithm Hash digest
SHA256 9159bf04c0537327fe2722d6a7d5ac4daa0bf9a2aef4d1f29ecf84c872f6e757
MD5 9d98bff77bd52e91f960c717bdd14ecc
BLAKE2b-256 e4b8557d8da9dfbc757b1abc862b6524ad76d079280ffbed20d6a042a4fea677

See more details on using hashes here.

File details

Details for the file yt2term-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: yt2term-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 6.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.11

File hashes

Hashes for yt2term-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 68bdd5146fb213637a930ee43bc35e0de2b93735f6d74e8b1caa808c61b12b9e
MD5 a873f092a8431ecb905aed592af7f5ae
BLAKE2b-256 ddb0b131e098a3645d7fc56cc1be24be32d2f3abdfb26a1c3d8597754900511b

See more details on using hashes here.

Supported by

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