Skip to content

jairoblatt/asciyx

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

asciyx

A simple weekend project. No pretensions.

Converts video files into ASCII art video output. Each frame is rendered by mapping pixel luminance to characters from a configurable density ramp, producing either a new encoded video or a live terminal preview.

Two character modes are available: standard ASCII (8x8 bitmap cells) and Japanese katakana (16x8 bitmap cells).

Requirements

  • ffmpeg and ffprobe available in PATH

Building

cargo build --release

The binary will be at target/release/asciyx.

Usage

asciyx [OPTIONS]

Arguments

Flag Short Type Default Description
--input -i <path> video.mp4 Path to the input video file
--output -o <path> video-processed.mp4 Path for the output video file (used when sink is video)
--sink -S video | terminal video Where to send the rendered output
--scale -s <uint> 1 Scale multiplier applied to each character cell
--density -d <uint> max for mode Number of characters in the luminance ramp (min 2, max depends on mode)
--loop -l <uint> 1 Number of times to loop playback
--japanese -j flag Use Japanese katakana characters instead of ASCII

Supported Formats

Input: any container format supported by ffmpeg (e.g. .mp4, .mkv, .avi, .mov, .webm). The path is passed directly to ffmpeg with no extension validation.

Output: the video sink encodes with libx264 + yuv420p, so the output container must be H.264-compatible (e.g. .mp4, .mkv, .mov). Containers that do not support H.264 (e.g. .webm) will fail.

Demo

ASCII mode

example-ascii.mp4

Katakana mode (-j)

example-j.mp4

Examples

Convert a video to ASCII art and save it:

asciyx -i input.mp4 -o output.mp4

Preview in the terminal with 2x scale and katakana mode:

asciyx -i input.mp4 --sink terminal --scale 2 --japanese

Reduce the character density ramp:

asciyx -i input.mp4 --density 10

About

Render any video as animated characters, live in the terminal or exported as a new video. Supports ASCII and Japanese katakana modes.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages