PBMREDUCE(1)

πŸ“¦
version 11.13.03 Β· 4 versions
, in debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking

✨ pbmreduce β€” the Pbmreduce User Manual, bestie edition ✨

okay so welcome to Pbmreduce User Manual(1), the glow-up guide πŸ’… this is a General Commands Manual moment and honestly? iconic.


🌸 NAME 🌸

pbmreduce β€” read a PBM image and reduce it N times πŸ¦‹


πŸŽ€ SYNOPSIS πŸŽ€

pbmreduce [-floyd|-fs|-threshold] [-value val] [-randomseed=integer] N
[pbmfile]

also, PSA: you can abbreviate any option to its shortest unique prefix. yes fr, go off king πŸ’œ


✨ DESCRIPTION ✨

so first things first: this program is part of Netpbm(1). family reunion 🫢

pbmreduce reads a PBM image as input and reduces it by a factor of N, producing a PBM image as output. in and out, PBM to PBM, no drama.

ngl, pbmreduce duplicates a lot of the functionality of pamditherbw. like you could do something like pamscale | pamditherbw, but pbmreduce is a lot faster. speed. it's giving main character energy ⚑

here's the fun part: you can use pbmreduce to "re-halftone" an image. let's say you have a scanner that only produces black&white, not grayscale, and it does a terrible job of halftoning (most b&w scanners fit this description, unfortunately 😭). one way to fix the halftoning is to scan at the highest possible resolution, say 300 dpi, and then reduce by a factor of three or so using pbmreduce. you can even correct the brightness of an image, by using the -value option. obsessed πŸ₯°


πŸ’– OPTIONS πŸ’–

so in addition to the options common to all programs based on libnetpbm (most notably -quiet, see Common Options), pbmreduce recognizes the following command line options:

  • -threshold β€” by default, pbmreduce does the halftoning after the reduction via boustrophedonic Floyd-Steinberg error diffusion; but you can use this option to specify simple thresholding instead. this gives better results when reducing line drawings. use it for those ✏️ moments.
  • -floyd, -fs β€” specify the Floyd-Steinberg error diffusion method. this is the default, bestie. it's just built different.
  • -value β€” this option alters the thresholding value for all quantizations. it should be a real number between 0 and 1. above 0.5 means darker images; below 0.5 means lighter. so like, turn the dial, no cap 🎚️
  • -randomseed=integer β€” this is the seed for the random number generator that controls the halftoning. use this to ensure you get the same image on separate invocations. reproducibility slay πŸ”₯
this option was new in Netpbm 10.75 (June 2016). a little baby option, we love her πŸ’•

πŸ¦‹ SEE ALSO πŸ¦‹

pamenlarge(1), pamscale(1), pamditherbw(1), pbm(1)

go read those too, they're the friend group 🌈


πŸ‘‘ AUTHOR πŸ‘‘

Copyright (C) 1988 by Jef Poskanzer. legend behaviour, we respect it πŸ’œ


πŸ“š DOCUMENT SOURCE πŸ“š

This manual page was generated by the Netpbm tool makeman from HTML source. The master documentation is at

http://netpbm.sourceforge.net/doc/pbmreduce.html

and that's the whole page bestie 🫢 this was netpbm documentation, dated 13 April 2016, and it's still giving Pbmreduce User Manual(1) energy. mwah πŸ’‹ go reduce something ✨

πŸ“¦ where this page comes from