| 1 |
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.3//EN"> |
| 2 |
<html><head><title>Pbmtopgm User Manual</title></head> |
| 3 |
<body> |
| 4 |
|
| 5 |
<h1>pbmtopgm</h1> |
| 6 |
Updated: 05 Feb 2003 |
| 7 |
<br> |
| 8 |
<a href="#index">Table Of Contents</a> |
| 9 |
|
| 10 |
<h2>NAME</h2> |
| 11 |
|
| 12 |
pbmtopgm - convert PBM image to PGM by averaging areas |
| 13 |
|
| 14 |
<h2 id="synopsis">SYNOPSIS</h2> |
| 15 |
|
| 16 |
<b>pbmtopgm </b> |
| 17 |
<i>width</i> |
| 18 |
<i>height</i> |
| 19 |
[<i>pbmfile</i>] |
| 20 |
|
| 21 |
<h2 id="description">DESCRIPTION</h2> |
| 22 |
|
| 23 |
<p>This program is part of <a href="index.html">Netpbm</a>. |
| 24 |
|
| 25 |
<p><b>pbmtopgm</b> reads a PBM image as input. It outputs a PGM image |
| 26 |
in which each pixel's gray level is the average of the surrounding |
| 27 |
black and white input pixels. The surrounding area is a rectangle of |
| 28 |
<i>width</i> by <i>height</i> pixels. |
| 29 |
|
| 30 |
<p>In other words, this is a convolution. <b>pbmtopgm</b> is similar |
| 31 |
to a special case of <b>pnmconvol</b>. |
| 32 |
|
| 33 |
<p>You may need a <b>pnmsmooth</b> step after <b>pbmtopgm</b>. |
| 34 |
|
| 35 |
<p><b>pbmtopgm</b> has the effect of anti-aliasing bitmaps which |
| 36 |
contain distinct line features. |
| 37 |
|
| 38 |
<p><b>pbmtopgm</b> works best with odd sample width and heights. |
| 39 |
|
| 40 |
<p>You don't need <b>pbmtopgm</b> just to use a PGM program on a PBM |
| 41 |
image. Any PGM program (assuming it uses the Netpbm libraries to read |
| 42 |
the PGM input) takes PBM input as if it were PGM, with only the |
| 43 |
minimum and maximum gray levels. So unless your convolution rectangle |
| 44 |
is bigger than one pixel, you're not gaining anything with a |
| 45 |
<b>pbmtopgm</b> step. |
| 46 |
|
| 47 |
<p>The opposite transformation (which would turn a PGM into a PBM) is |
| 48 |
dithering. See <b>pamditherbw</b>. |
| 49 |
|
| 50 |
<h2 id="options">OPTIONS</h2> |
| 51 |
|
| 52 |
<p>There are no command line options defined specifically |
| 53 |
for <b>pbmtopgm</b>, but it recognizes the options common to all |
| 54 |
programs based on libnetpbm (See <a href="index.html#commonoptions"> |
| 55 |
Common Options</a>.) |
| 56 |
|
| 57 |
<h2 id="seealso">SEE ALSO</h2> |
| 58 |
|
| 59 |
<b><a href="pamditherbw.html">pamditherbw</a></b>, |
| 60 |
<b><a href="pnmconvol.html">pnmconvol</a></b>, |
| 61 |
<b><a href="pbm.html">pbm</a></b>, |
| 62 |
<b><a href="pgm.html">pgm</a></b> |
| 63 |
|
| 64 |
<h2 id="author">AUTHOR</h2> |
| 65 |
|
| 66 |
<p>Copyright (C) 1990 by Angus Duggan. |
| 67 |
<p>Copyright (C) 1989 by Jef Poskanzer. |
| 68 |
|
| 69 |
<p>Permission to use, copy, modify, and distribute this software and |
| 70 |
its documentation for any purpose and without fee is hereby granted, |
| 71 |
provided that the above copyright notice appear in all copies and that |
| 72 |
both that copyright notice and this permission notice appear in |
| 73 |
supporting documentation. This software is provided "as is" |
| 74 |
without express or implied warranty. |
| 75 |
|
| 76 |
<hr> |
| 77 |
<h2 id="index">Table Of Contents</h2> |
| 78 |
<ul> |
| 79 |
<li><a href="#synopsis">SYNOPSIS</a> |
| 80 |
<li><a href="#description">DESCRIPTION</a> |
| 81 |
<li><a href="#options">OPTIONS</a> |
| 82 |
<li><a href="#seealso">SEE ALSO</a> |
| 83 |
<li><a href="#author">AUTHOR</a> |
| 84 |
</ul> |
| 85 |
</body> |
| 86 |
</html> |