dotmax
Render anything in terminal braille. Images, GIFs, videos, webcam - one line of code.

Gallery
Color Rendering
|
|
 |
 |
| Full-color image rendering with braille dots |
Color rendering with tuner overlay |
 |
 |
| High-detail color closeup |
Medium-resolution color render |
Monochrome & Pixel Sizes
|
|
 |
 |
| 8px monochrome braille |
Small pixel density |
 |
 |
| Small pixel snake render |
Large pixel with shading enabled |
 |
 |
| Large pixel monochrome |
Animated GIF playback in terminal |
3D, Audio & More
|
|
 |
 |
| 3D sphere wireframe (OBJ rendering) |
Sphere with I/O overlay |
 |
 |
| 3D snake head model |
Audio spectrograph visualization |
 |
|
| Grid/oscilloscope formation |
|
Install
cargo add dotmax --features image
One-Line Usage
use dotmax::quick;
quick::show_file("photo.png")?; quick::show_file("cat.gif")?; quick::show_file("movie.mp4")?; quick::show_webcam()?;
Features
| Feature |
What it enables |
Install |
image |
PNG, JPG, GIF, APNG, BMP, WebP, TIFF |
cargo add dotmax --features image |
svg |
SVG vector graphics |
cargo add dotmax --features svg |
video |
Video + webcam (needs FFmpeg) |
cargo add dotmax --features video |
[dependencies]
dotmax = { version = "0.1", features = ["image"] }
dotmax = { version = "0.1", features = ["image", "svg"] }
dotmax = { version = "0.1", features = ["video"] }
Video feature requires FFmpeg installed on your system.
Quick API Reference
use dotmax::quick;
quick::show_file("any.png")?; quick::show_image("photo.jpg")?; quick::show_webcam()?; quick::show_webcam_device(0)?; quick::show_webcam_device("/dev/video1")?;
let grid = quick::load_image("photo.png")?; quick::show(&grid)?;
let mut grid = quick::grid()?;
Drawing Primitives
use dotmax::prelude::*;
let mut grid = grid()?;
draw_line(&mut grid, 0, 0, 100, 50)?;
draw_circle(&mut grid, 50, 25, 20)?;
draw_rectangle(&mut grid, 10, 10, 80, 40)?;
show(&grid)?;
Animation Loop
use dotmax::animation::AnimationLoop;
AnimationLoop::new(80, 24)
.fps(30)
.on_frame(|frame, grid| {
grid.clear();
grid.set_dot((frame * 2) % 160, 48)?;
Ok(true) })
.run()?;
Examples
cargo run --example hello_braille
cargo run --example bouncing_ball
cargo run --example shapes_demo
cargo run --example load_image --features image
cargo run --example dither_comparison --features image
cargo run --example animated_gif --features image -- your.gif
cargo run --example animated_apng --features image -- your.apng
cargo run --example video_player --features video -- your.mp4
cargo run --example webcam_viewer --features video
cargo run --example webcam_tuner --features video
Tuners
Tuners let you find the best render settings visually. Adjust dithering, brightness, contrast, etc. in real-time and see the results instantly.
Why use a tuner?
Different images/videos look best with different settings. Instead of guessing values in code, use the tuner to experiment live, then copy the settings you like.
Webcam Tuner
cargo run --example webcam_tuner --features video
Video/Image Tuner
cargo run --example render_tuner --features video -- your_video.mp4
cargo run --example render_tuner --features image -- your_image.png
Tuner Controls
| Key |
Action |
| D |
Cycle dithering (Floyd/Bayer/Atkinson/None) |
| T |
Toggle threshold (Auto/Manual) |
| +/- |
Adjust threshold ±10 |
| [/] |
Adjust threshold ±1 |
| B/b |
Brightness +/- |
| C/c |
Contrast +/- |
| G/g |
Gamma +/- |
| M |
Toggle color mode (Mono/Color) |
| R |
Reset all settings |
| H |
Help |
| Q |
Quit |
What the settings do
- Dithering: How dots are distributed. Floyd-Steinberg = smooth gradients, Bayer = patterned, Atkinson = high contrast, None = pure threshold
- Threshold: Brightness cutoff for black vs white. Auto (Otsu) calculates optimal value. Manual lets you pick 0-255
- Brightness/Contrast/Gamma: Standard image adjustments. Useful for dark or washed-out sources
Performance
| Operation |
Time |
| Frame render (80×24) |
~2μs |
| Image load + render |
~10ms |
| 60fps animation budget |
16.6ms (we use 1.6μs) |
License
MIT OR Apache-2.0