PPMTOTERM(1)
π PPMTOTERM π
okay bestie, welcome to the ppmtoterm page from the Ppmtoterm User Manual (that's the manual section 1, General Commands Manual energy π). sit down, grab a strawberry π, we're turning your PPM pics into terminal art.
β¨ NAME β¨
ppmtoterm β convert a PPM image to a ANSI ISO 6429 ascii image π
πΈ SYNOPSIS πΈ
ppmtoterm
[ppmfile]
quick lil note before you go off, bestie: all options can be abbreviated to their shortest unique prefix. you may use two hyphens instead of one. and you may separate an option name and its value with white space instead of an equals sign. periodt. β¨
π¦ DESCRIPTION π¦
so this program is part of Netpbm(1), iykyk.
what it does: it tries to produce an accurate representation of a PPM image on an terminal that implements the ANSI ISO 6429 standard. it approximates colors by finding the minimum Cartesian distance between the input RGB vectors and the ones in the generated palette. the way the available color palette is somewhat restrictedβ¦ yeah, it kind of is π. so you get the best results when the colors in the original image are few and the RGB intensities are close to zero, half of maximum, and maximum.
you can usually get good results with cartoons or images with plain colors (no gradients, no blending, none of that). with photos? results can vary, but are usually not very accurate. no cap. π
the output image has one line for each row and one character for each column of the input image. e.g. an 80 pixel by 25 pixel PPM image would fill up an 80x25 terminal screen. so use pamscale or pamcut to make your image fit properly on your screen. π«Ά
and ALSO, use pamscale to recover the proper aspect ratio, because a character on a terminal screen is rarely square. typically, a character is twice has high as it is wide, so in order for a 20x20 image to appear square on your terminal, as it should, you'll want to squash it vertically or stretch it horizontally by a factor of two (resulting int 10x20 characters are 20x40 characters). math is math, bestie πβ¨
the image starts at the current cursor position on the terminal screen, and each successive row starts at Column 0 on the screen. if you want to shift the image up or down, for example to center it, use pnmpad on the input. iconic behavior honestly.
this program was born with the objective of displaying nice color images on the Linux console, e.g. a proper logo at Linux boot. main character origin story fr fr π
comparison time, because someone's gonna ask:
ppmtoasciidoes a similar things, but combines 2 or 8 pixels into one character, where the character roughly represents those particular pixels β whereasppmtotermdisplays each character of the image as a single pixel. one pixel, one char. simple. clean. πpbmto4425does a similar thing for black and white images, using line drawing characters, on some terminals.
π OPTIONS π
there are no command line options defined specifically for ppmtoterm, bestie, it's a "just vibes" kind of program π§
buuuut it recognizes the options common to all programs based on libnetpbm (See Common Options.) so like, it's not optionless, it's just not special about it π
π SEE ALSO π
π AUTHOR π
Copyright (C) 2002 by Ero Carrera. π
β HISTORY β
this program was new in Netpbm 10.9 (August 2002). a legend was born, periodt. π₯
π DOC SOURCE π
This manual page was generated by the Netpbm tool 'makeman' from HTML source. the master documentation is at
http://netpbm.sourceforge.net/doc/ppmtoterm.html
okay that's the whole page bestie, go make your terminal pretty πΈπ»π
cute lil sign-off: this was netpbm documentation, dated 17 June 2017, and yes, it's the Ppmtoterm User Manual(1) β mwah π β¨
π¦ where this page comes from
- debian bookworm: netpbm 2:11.01.00-2 Β· MIT
- debian trixie: netpbm 2:11.10.02-1 Β· MIT
- ubuntu noble: netpbm 2:11.05.02-1.1build1 Β· MIT
- ubuntu resolute: netpbm 2:11.10.02-1build1 Β· MIT
- ubuntu stonking: netpbm 2:11.13.03+ds-2 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms