pbmtoascii(1) - man - phpman

Look up a command

 

Markdown Format | JSON API | MCP Server Tool | Cheat Sheet


TLDR: pbmtoascii (tldr-pages)

Convert a PBM image to ASCII graphics.

  • Read a PBM file as input and produce an ASCII output
    pbmtoascii {{path/to/input_file.pbm}}
  • Read a PBM file as input and save an ASCII output into a file
    pbmtoascii {{path/to/input_file.pbm}} > {{path/to/output_file}}
  • Read a PBM file as input while setting the pixel mapping (defaults to 1x2)
    pbmtoascii -{{1x2|2x4}} {{path/to/input_file.pbm}}
  • Display version
    pbmtoascii {{-v|-version}}
pbmtoascii(1)                          General Commands Manual                         pbmtoascii(1)



NAME
       pbmtoascii - convert a portable bitmap into ASCII graphics

SYNOPSIS
       pbmtoascii [-1x2|-2x4] [pbmfile]

DESCRIPTION
       Reads a portable bitmap as input.  Produces a somewhat crude ASCII graphic as output.

       Note that there is no asciitopbm tool - this transformation is one-way.

OPTIONS
       The -1x2 and -2x4 flags give you two alternate ways for the bits to get mapped to characters.
       With 1x2, the default, each character represents a group of 1 bit  across  by  2  bits  down.
       With -2x4, each character represents 2 bits across by 4 bits down.  With the 1x2 mode you can
       see the individual bits, so it's useful for previewing small bitmaps on a non-graphics termi‐
       nal.   The  2x4  mode lets you display larger bitmaps on a standard 80-column display, but it
       obscures bit-level details.  2x4 mode is also good for displaying graymaps - "pnmscale -width
       158 | pgmnorm | pgmtopbm -thresh" should give good results.

SEE ALSO
       pbm(5)

AUTHOR
       Copyright (C) 1988, 1992 by Jef Poskanzer.



                                            20 March 1992                              pbmtoascii(1)

Generated by phpMan Author: Che Dong Under GNU General Public License
2026-06-02 17:43 @216.73.216.151 CrawledBy Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
Valid XHTML 1.0 TransitionalValid CSS!