Copenhagen

timg – Terminal Image and Video Viewer

In Operation

Here’s an image displayed by timg in a terminal. We’re using the Kitty terminal emulator. As timg supports the Kitty Graphics Protocol, we see the image in its full 24-bit glory.

timg
Click image for full size

Besides support for the Kitty Graphics Protocol, the software can display images with half blocks, quarter blocks, and there’s support for iTerm2 graphics as well. In the image above which is shown using kitty graphics we didn’t need to specify the mode as the software auto-detects graphics.

Images can be displayed in a configurable grid. This is especially handy if you’re looking for a specific image buried among in a directory of many images. In the screenshot below, we’ve chosen a grid of 5 images across. By including the –title option you can see the associated filenames (not shown in the image).

timg - grid view
Click image for full size

There are other command-line options which let us define things like output geometry, scale to fit width, rotate, auto-crop, background colour and more.

timg is a lot more than just an image viewer. It also supports playback of GIF animations. There’s support for upscaling which enlarges images and animations so that they fit the window.

And the icing on the cake is support for playback of video. Videos play once, but it’s possible to define the number of runs through a full cycle, or to stop at a specified time interval.


Summary

timg is an excellent image viewer for the terminal with a good set of features including grid views. It trumps viu in our opinion offering more functionality and better supported for animated GIFs.

Playback of video works well although without support for audio or subtitles, it’s usefulness is somewhat limited.

Website: github.com/hzeller/timg
Support:
Developer: Henner Zeller
License: GNU General Public License v2.0

timg is written in C++. Learn C++ with our recommended free books and free tutorials.

Pages in this article:
Page 1 – Introduction / Installation
Page 2 – In Operation / Summary

Related Software

Terminal-Based Image Viewers
timgImage and video viewer with good range of features. Written in C++
ChafaCharacter Art Facsimile
viuRust-based image viewer
vvImage viewer for sixel terminals
TIVTiny C++ program that displays images in a terminal
RangerTerminal-based file manager supporting high quality previews of images
mcatExtended cat command
icatCat like utility can specify multiple image files and/or directories
PixelTerm-CHigh-performance terminal image browser written in C
phoLightweight image viewer
catimgRenders images in the terminal
PTUIReal-time image preview capabilities
imvX11/Wayland image viewer
ivImage viewer using terminal graphics
TermVisageFront-end to the term-image library
FotoSimple image viewer
vatRenders SVG and other vector graphics in multiple formats
image_to_consoleFast image viewer supporting animations and graphics protocols
rsimgUses crossterm and zune as dependencies
imgcatDisplays images and gifs in your terminal emulator.

Read our verdict in the software roundup.


Best Free and Open Source Software LinuxLinks helps you discover the best free and open source software for Linux. Explore our extensive collection of recommended applications, including alternatives to popular proprietary software.

We also publish software reviews, Linux tutorials, hardware reviews, free programming books and articles covering the wider open source community. Browse our Linux resources to discover more.

Know a useful free and open source Linux application we haven't covered? Suggest a program for inclusion.

Has your software been featured on LinuxLinks? Display one of our Featured on LinuxLinks badges on your website or GitHub README.
Subscribe

Please read our Comment Policy before commenting.

Notify of
guest
0 Comments
Oldest
Newest Most Voted