Term-image-tor

A command-line tool that renders images, animated GIFs, and live webcam feeds directly in the terminal using colored Unicode block characters. Built in Rust.

Monet's Water Lilies rendered in the terminal using colored block characters

It uses the half-block character with ANSI colour codes — each character cell encodes two vertical pixels, giving surprisingly detailed results. Supports both 256-colour and 24-bit truecolour modes.

How it works

The tool loads an image, resizes it to fit the terminal using Lanczos3 resampling, then iterates pixel rows in pairs — background colour for the top pixel, foreground colour for the bottom, printing . Animated GIFs are pre-resized on load and played back by overwriting frames with cursor escape sequences. The webcam uses the same technique in a continuous loop.

A starry night sky rendered in the terminal

Features

Static images (PNG, JPEG, WebP, and more), animated GIF playback, and live webcam streaming. Configurable width, automatic aspect ratio preservation, and two colour modes — 256-colour for universal terminal support and truecolour for maximum fidelity.

View on GitHub →


Back to projects