Øyvind Kolås    pippin@gimp·org twitter github bitcoin patreon  

tv - terminal viewer

interactive high fidelity terminal/console image viewer, using unicode, truecolor or sixels with slideshow and PDF integration

gnome-terminal, unicode truecolor

xterm, sixel, 16 colors (DEC VT340 terminals might be able to show this)


  • slide show with configurable timeout
  • 16 color/gray sixel support, as for vt340 - as well as more colors for mlterm
  • linux framebuffer support
  • gamma correct (linear light resampling)
  • pan and zoom to fit, fill and width
  • JPG, PNG, TGA, BMP, PSD, GIF, HDR, PIC, PPM, PGM (using libjpeg, libpng and stb_image)
  • auto-detects sixel support, sixel support being useful for running the viewer on a server through ssh connections and get high resolution images viewed within the encrypted session.
  • on demand PDF page rasterization with external ghostscript (gs) binary
  • dithering, when used is the addition based variant of arithmetic dither

Space / backspace for moving through slides, +/- for zoom in and out, cursor keys to pan, S to toggle slideshow F to zoom to fit, W to zoom to width (and go top top - default for PDF pages.), j - jump to a specific frame number, shift-s to set slideshow delay, g to toggle grayscale, d to toggle dithering

$ tv --help
usage: tv [--help] [-w <width>] [-h <height>] -m <mode> [images]
  --help  print this help
  -s <wxh> width x height
       the dimension is in pixels for sixel modes and in character
       cells for character based modes
  -o <thumbpath> write a thumbnail with -s' dimensions to thumb_path
  -d <delay_seconds> set number of seconds of sleep between images in slideshow
  -m <mode>  specify no or invalid mode to get a list of valid modes


Since my Patreon has been going well in its first week, I've pushed these sources to a public spot as well, ejoy :)



x86 binary <900kb statically linked with musl, libpng and libjpeg - should work on most 32bit and 64bit x86 linux distros - download and chmod a+x tv, then ./tv to run it.

potential future development

  • deletion
  • rotation
  • live filtering
  • thumbnail generation/view
  • file system monitoring
  • gif animation support through libnsgif
mlterm, sixel, 256 colors palette, dithering using a-dither'

sixels are a six pixels per character DEC printer/terminal graphics format supported by some actual serial terminals, terminal emulators and printer. It permits showing images inline with text or even doing interactive graphics applications.

linux /dev/fb0 framebuffer - 16bpp

Using a-dither - and the same code for keyboard interaction as the other terminal graphics backends.

ascii mode

The ASCII mode maps grayscale to a 1bit dithered 2x2 super resolution grid.

xterm, sixel, 16 grays, probably tenable on DEC VT340
xterm, sixel, mono, using a-dither

Included in this gallery for completeness - illustrating how a-dither behaves for the worst-case scenario, 2 output colors.

xterm, 256 color (with xterm mapping 24bit escape sequences itself), unicode

linux /dev/fb0 framebuffer - 8bpp