Skip to content

josharian/vidcat

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

vidcat

Convert video files to compressed terminal ANSI streams for playback.

Inspired by Simon Willison, who was in turn inspired by Darren Burns.

Warning: vibe-coded

Demo

vidcat demo

How it works

It takes a video file, extracts frames with ffmpeg, converts each frame to ANSI escape sequences with randomized pixel ordering (anti-tearing effect), and compresses the stream with zstd.

Dependencies

ffmpeg, pv, zstd

# macOS
brew install ffmpeg pv zstd

# Ubuntu/Debian
sudo apt install ffmpeg pv zstd

Python dependencies are managed with uv (see script header).

Usage

Convert a video to an ANSI stream:

uv run vidcat.py path/to/video.mp4 --width 80 --output video.zst

Warning big width means big output file.

vidcat prints playback instructions at the end of the conversion.

License

MIT.

If you really want this code. But I don't know why you would.

About

video -> terminal playback

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages