1Pnmsmooth User Manual(0)                              Pnmsmooth User Manual(0)
2
3
4

NAME

6       pnmsmooth - smooth out an image
7
8

SYNOPSIS

10       pnmsmooth [-width=cols] [-height=rows] [pnmfile] [-size]
11
12       Minimum  unique  abbreviations  of  options is acceptable.  You may use
13       double hyphens instead of single hyphen to denote options.  You may use
14       white space in place of the equals sign to separate an option name from
15       its value.
16
17

DESCRIPTION

19       This program is part of Netpbm(1).
20
21       pnmsmooth smoothes out an image by replacing each pixel with the  aver‐
22       age  of  its  width  X height neighbors.  It is implemented as a progam
23       that invokes pnmconvol with an appropriate convolution matrix.
24
25

OPTIONS

27       -width=cols
28
29       -height=rows
30              These options specify the dimensions of the convolution  matrix.
31              Default dimensions are 3 wide and 3 high.
32
33              Before  Netpbm  10.49  (December  2009), the maximum size of the
34              convolution matrix is limited by the maxval of  the  image  such
35              that  width  *  height  *  2  must  not exceed the maxval.  (use
36              pamdepth to increase the maxval if necessary).
37
38              These options were new in Netpbm 10.32 (February 2006).   Before
39              that, use -size.
40
41
42       -size  This  deprecated  option  exists  in current Netpbm for backward
43              compatibility.  It was obsoleted by -width and -height in Netpbm
44              10.32 (February 2006).
45
46              When  you  use  this option, the first two program arguments are
47              the width and height, respectively, of  the  convolution  matrix
48              and  do  the same thing as the -width and -height option values.
49              The third (optional) program argument is the input file name.
50
51              In reality, in old pnmsmooth, the width and height are two  val‐
52              ues  of  the  -size option, but the modern Netpbm command syntax
53              paradigm doesn't  allow  an  option  with  multiple  values,  so
54              instead  -size  is  an option with no value and width and height
55              are program arguments.  That has the fortunate effect of  making
56              the  following  command mean the same in current pnmsmooth as in
57              old pnmsmooth:
58                   pnmsmooth -size 5 5 infile.ppm >outfile.ppm
59
60
61       -dump=dumpfile
62              This options makes  pnmsmooth  only  show  you  the  convolution
63              matrix.  It writes to Standard Output a pnmconvol -matrix option
64              value that represents the matrix.  It does not invoke  pnmconvol
65              and does not produce an output image.
66
67              Before  Netpbm 10.49 (December 2009), this option is rather dif‐
68              ferent.  It takes a file name as a value, and it writes to  that
69              file  the  convolution  matrix  as a PGM file (as used to be the
70              normal input for pnmconvol).
71
72
73
74
75
76

SEE ALSO

78       pnmconvol(1), pnm(1)
79
80

HISTORY

82       Before Netpbm 10.32 (February 2006), pnmsmooth did not use  the  modern
83       Netpbm  command line parser, so had an unconventional command line syn‐
84       tax.  Most importantly, you could not  use  an  equal  sign  or  double
85       hyphens in the options.
86
87       Before  Netpbm  10.49  (December 2009), there was a -dump option.  This
88       strange option caused pnmsmooth not to do any smoothing or produce  any
89       output  image  but  instead  write the convolution matrix it would have
90       used, as PGM file such as pnmconvol used to use, to a file you specify.
91       The idea was you could then use that file with a separate invocation of
92       pnmconvol.
93
94       Then, in Netpbm 10.49, there was a rather different -dump option with a
95       similar  purpose:  It  caused  pnmsmooth  to  write to Standard Error a
96       string suitable as a value for the pnmconvol -matrix option (an  option
97       that was new in Netpbm 10.49).
98
99       But in Netpbm 10.51 (June 2010), pnmconvol started using the even newer
100       pnmconvol -normalize option (new in 10.50), which made  specifying  the
101       convolution  matrix for the kind of smoothing that pnmsmooth does triv‐
102       ial, so -dump disappeared from pnmsmooth.
103
104       (There were also ease of implementation issues that kept us from simply
105       keeping  the  original  -dump  around for backward compatibility: As we
106       modified pnmsmooth to take advantage of the new features of  pnmconvol,
107       which  pnmsmooth  uses  internally, the information needed to implement
108       -dump was no longer available in the program).
109

DOCUMENT SOURCE

111       This manual page was generated by the Netpbm tool 'makeman'  from  HTML
112       source.  The master documentation is at
113
114              http://netpbm.sourceforge.net/doc/pnmsmooth.html
115
116netpbm documentation           19 December 2009       Pnmsmooth User Manual(0)
Impressum