Skip to content

Have you ever wanted to know what an image looks like without having to leave the terminal? Well you're in luck! Now you can "cat" images with this utility called ICat (short for image cat)!

License

Notifications You must be signed in to change notification settings

M-Valentino/ICat

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

63 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ICat v1.2.0

Have you ever wanted to know what an image looks like without having to leave the terminal? Well you're in luck! Now you can "cat" images with this utility called ICat (short for image cat)! ICat works by reading images and converting them to ASCII text. Images printed to the terminal are displayed in greyscale with 5 colors.

ICat is primarily built with Python.

Requirements

The following is needed on your Mac or Linux installation in order to run ICat:

  • Python3
  • CairoSVG Python library
  • numPy Python library
  • pathlib Python library
  • Pillow Python library

Icat can automatically install the latest versions of these libraries if you wish.

Installation

Clone the git repo anywhere you like and then run ./install.sh. If you get a Permission denied error, run the chmod command to change the file's permissions. The directory ICat is installed to is /usr/local/bin/. If you delete your local clone of the ICat repo, the installation will not be affected.

When installing, you will be prompted to answer if your terminal is light or dark. This is to ensure that images display properly and don't appear inverted. You will also be asked if this character, '▓' appears as a square. This is to ensure that images don't appear stretched. If the character appears as a rectangle, images will be printed in "half pixels", and as a result, will have more horizontal detail.

Running

To use ICat, run icat 'imageFilename'. You can add arguments after the file name argument.

  • -c applies a contour filter to the image.
  • -i inverts the image.
  • -s sharpens the image.
  • x1.5 prints image 1.5x larger than the default size.
  • x2 prints image 2x larger than the default size.
  • -settings Changes the settings of ICat.
  • -version Displays the version of ICat installed.

Example

icating this image:

Produces this result:

About

Have you ever wanted to know what an image looks like without having to leave the terminal? Well you're in luck! Now you can "cat" images with this utility called ICat (short for image cat)!

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published