timg is your lightweight terminal-based image and video viewer that seamlessly harnesses your terminal's graphic capabilities. From full-resolution displays on Sixel and Kitty to clever block displays, timg makes previewing visuals straightforward without the need for bulky applications. Perfect for remote sessions or quick checks, it integrates visuals right into your command line workflow.
timg is a powerful terminal image and video viewer designed to leverage the graphical capabilities of various terminal types, including support for Sixel, Kitty, and iTerm2 protocols. This lightweight solution allows users to display images in full resolution or make use of 24-Bit color capabilities along with Unicode character blocks for terminals without advanced graphics support.
Key Features:
- Display Images and Videos: Quickly view regular images, animated GIFs, and videos directly in your terminal without relying on traditional, bulky image viewing applications.
- High-Resolution Output: On compatible terminals that support specific graphics protocols, timg can display images at full resolution, enhancing your visuals significantly.
- Fallback Compatibility: Even if your terminal doesn’t support high-resolution graphics, you can still utilize effective block character rendering to visualize images.
Installation and Usage
With a simple command-line interface, timg allows you to display single images or multiple images sequentially or in a grid layout. Here are some usage examples:
# Display a static image
$ timg some-image.jpg
# Display multiple images
$ timg *.jpg
# Show images in a grid format
$ timg --grid=3 *.jpg
Explore more advanced usage options such as specifying pixelation modes, centering images, and customizing titles.
Supported Pixelation Modes:
Pixelation Type | Description |
---|---|
Half Blocks | Great color accuracy at a lower resolution |
Quarter Blocks | Higher spatial resolution with slight color inaccuracies |
Kitty Graphics | Full resolution output possible |
iTerm2 Graphics | Ideal for images displayed on iTerm2 |
Interactive Grid Display:
You can effortlessly navigate through a collection of images by arranging them in a grid. For quick browsing, you can enable titles that correspond to each image filename, maximizing productivity during your visual checking tasks:
$ timg --grid=3 --title *.jpg
Additional Flexibility:
Integrate timg into your terminal-based file browser easily, enhancing your file management experiences without compromising productivity. You can also manipulate images from the command line using various options to adjust layout, scrolling, and background settings with a rich array of commands.
Experience a new level of efficiency in your workflow by bringing image and video viewing capabilities directly to your terminal with timg. Whether for remote sessions, quick image checks, or staying within the command line interface, timg enhances your terminal experience seamlessly.