summary refs log tree commit diff
diff options
context:
space:
mode:
authorgiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2023-09-07 16:26:28 +0000
committergiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2023-09-07 16:26:28 +0000
commit851f8a113827e42ae618423fdab09cb0a67dc4e4 (patch)
treec7975f26f69fa817d5de575a5c97d0a585b4e999
parent3195997e71a1ad9686da91a1d14cda2d81d3eb52 (diff)
downloadnetpbm-mirror-851f8a113827e42ae618423fdab09cb0a67dc4e4.tar.gz
netpbm-mirror-851f8a113827e42ae618423fdab09cb0a67dc4e4.tar.xz
netpbm-mirror-851f8a113827e42ae618423fdab09cb0a67dc4e4.zip
miscellaneous update
git-svn-id: http://svn.code.sf.net/p/netpbm/code/userguide@4637 9d0c8265-081b-0410-96cb-a4ca84ce46f8
-rw-r--r--pamaddnoise.html99
-rw-r--r--pbmmake.html9
-rw-r--r--ppmrough.html86
3 files changed, 108 insertions, 86 deletions
diff --git a/pamaddnoise.html b/pamaddnoise.html
index 3a0f3903..0d1609bd 100644
--- a/pamaddnoise.html
+++ b/pamaddnoise.html
@@ -2,7 +2,7 @@
 <html><head><title>Pamaddnoise User Manual</title></head>
 <body>
 <h1>pamaddnoise</h1>
-Updated: 12 December 2020
+Updated: 21 August 2023
 <br>
 <a href="#index">Table Of Contents</a>
 
@@ -81,60 +81,97 @@ Common Options</a>), <b>pamaddnoise</b> recognizes the following
 command line options:
 
 <dl compact>
-<dt><b>-lambda</b> <i>value</i>
+<dt><b>-type</b> <i>noise_type</i>
+
+<dd>
+Select type of noise by name.  The following noise types are
+available: gaussian, multiplicative_gaussian, impulse, laplacian,
+poisson.  Only enough letters to be unique are required for the noise
+type option.  The default noise type is <b>gaussian</b>.
+
+<dl>
+<dt><b>gaussian</b>
+  <dd>To each sample value is added the value of a two Gaussian random variables.
+    The variance of one is independent of the sample value, while the variance
+    of the other is proportional to the sample value.  You control these
+    variances with options <b>-sigma1</b> and <b>-sigma2</b> (and can eliminate
+    either by setting the variance to 0).  The mean of the Gaussian
+    distributions is 0.
+
+<dt><b>multiplicative_gaussian</b>
+<dt><b>impulse</b>
+  <dd>This is &quot;salt and pepper&quot; noise.  Samples are changed randomly
+    to zero or full brightness or left alone.  This is also know as salt and
+    pepper noise, as in a grayscale picture, it adds white pixels and black
+    pixels, which look like salt and pepper, respectively.  Control this with
+    options <b>-tolerance</b> and <b>-salt</b>.
+
+<dt><b>laplacian</b>
+
+<dt><b>poisson</b>
+</dl>
 
-<dd>This is the expected value of the Poisson distribution for a sample value
-  of mximum intensity.  The expected value for other intensities is
-  proportional; e.g. for half intensity, it is half this value.
+<dt><b>-lambda</b> <i>value</i>
 
-<p>This is meaningful only with <b>-type=poisson</b>.
+<dd>
+This is valid only with <b>-type=poisson</b>.  It is the expected value
+of the Poisson distribution for a sample value of mximum intensity.  The
+expected value for other intensities is proportional; e.g. for half intensity,
+it is half this value.
 
 <p>The default value is 12.
 
 <dt><b>-lsigma</b> <i>value</i>
 
-<dd>Used for laplacian noise only.  The default value is 10.0.
+<dd>This is menaingful only for laplacian noise.
+
+<p>The default value is 10.0.
 
 <dt><b>-mgsigma</b> <i>value</i>
 
-<dd>Used for multiplicative gaussian noise only.  The default value is
-0.5.
+<dd>This is valid only for multiplicative gaussian noise.
+
+<p>The default value is 0.5.
 
 <dt><b>-seed</b> <i>int</i>
 
-<dd>Used for all noise types.  Set the initial random number generator
-seed value.
+<dd>This is the random number generator seed value.  Use this to get
+  repeatable results.
 
 <dt><b>-sigma1</b> <i>value</i>
 
-<dd>Used for gaussian noise only.  The default value is 4.0.
+<dd>This is valid only for gaussian noise.  It is the standard deviation
+  of the Gaussian random variable that is multiplied by the square root of
+  each sample value and added to that sample value.
+<p>
+    The default value is 4.0.
 
 <dt><b>-sigma2</b> <i>value</i>
 
-<dd>Used for gaussian noise only.  The default value is 20.0.
+<dd>This is valid only for gaussian noise.
+  It is the standard deviation of the Gaussian random variable that is
+  added directly to each sample value.
+<p>
+The default value is 20.0.
 
-<dt><b>-tolerance</b> <i>ratio</i>
+<dt><b>-tolerance</b> <i>fraction</i>
 
-<dd>
-Used for impulse noise only.  The default value is 0.10.  This means
-that 5% of all pixel values will be set to 0 and 5% will be set to
-the maxval
+<dd>This is valid only for impulse noise.
+  <i>fraction</i> is the fraction of samples that are changed
+  in the output.  Whether each is changed to salt or pepper is controlled by
+  <b>-salt</b>.
 
-<dt><b>-type</b> <i>noise_type</i>
+<p>The default value is 0.10.
 
-<dd>
-Select type of noise by name.  The following noise types are
-available: gaussian, multiplicative_gaussian, impulse, laplacian,
-poisson.  Only enough letters to be unique are required for the noise
-type option.  The default noise type is <b>gaussian</b>.
+<dt><b>-salt=<i>fraction</i></b>
+  <dd>This is valid only for impulse noise.  <i>fraction</i> is the
+    fraction of the pixels that are changed that are changed to salt (maxval);
+    the rest are changed to pepper (0).
 
-<ul>
-<li><b>gaussian</b>
-<li><b>multiplicative_gaussian</b>
-<li><b>impulse</b>
-<li><b>laplacian</b>
-<li><b>poisson</b>
-</ul>
+<p>The default is 0.5 (half salt, half pepper).
+
+<p>This option was new in Netpbm 11.04 (September 2023).  Before that, the
+  noise is always half salt and half pepper.
 
 </dl>
 
diff --git a/pbmmake.html b/pbmmake.html
index 06afbb73..4ed8358b 100644
--- a/pbmmake.html
+++ b/pbmmake.html
@@ -40,12 +40,11 @@ command line options:
 <dt><b>-black</b>
 <dt><b>-gray</b>
 
-<p>In addition to the usual <b>-white</b> and <b>-black</b>, this
-program implements <b>-gray</b>.  This gives a simple 50% gray pattern
-with 1's and 0's alternating.
+<p>These options specify the color of the output.  <b>-white</b> means
+all pixels are white.  <b>-black</b> means all pixels are black.
+<b>-gray</b> means black and white pixels alternate.
 
-<p>With none of the above specified, the output image will be entirely
-white.
+<p>You may specify only one of these.  The default is all white.
 
 </dl>
 
diff --git a/ppmrough.html b/ppmrough.html
index 7ecc343d..e31c4221 100644
--- a/ppmrough.html
+++ b/ppmrough.html
@@ -2,12 +2,13 @@
 <html><head><title>Ppmrough User Manual</title></head>
 <body>
 <h1>ppmrough</h1>
-Updated: 28 January 2022
+Updated: 20 August 2023
 <br>
 <a href="#index">Table Of Contents</a>
 
 <h2>NAME</h2>
-ppmrough - create PPM image of two colors with a ragged border between them
+ppmrough - create PPM image of a single color rectangle with ragged edges on a
+different color background
 
 <h2 id="synopsis">SYNOPSIS</h2>
 
@@ -43,37 +44,27 @@ name and its value with white space instead of an equals sign.
 
 <p>This program is part of <a href="index.html">Netpbm</a>.
 
-<p><b>ppmrough</b> generates a PPM image of the specified width, height, and
-colors.  <b>ppmrough</b> tiles the image into semi-rectangular regions with a
-ragged borders between them.  It calculates the fluctuations with
-pseudo-random numbers.
+<p><b>ppmrough</b> generates a PPM image of the specified width and height.
+  The image consists of a rectangle of the specified foreground color
+  surrounded by borders of the specified size and background color, except
+  that the boundary between the foreground rectangle and the borders is
+  ragged.  The ragged effect is random.
 
 <p><b>ppmrough</b> writes the PPM image to Standard Output.
 
 <p>The maxval of the output image is 255 (You can change this with
 <b>pamdepth</b>).
 
-<p>Use the options <b>-left</b> or <b>-right</b>, respectively, to
-make vertical borders, and <b>-top</b> or <b>-bottom</b>,
-respectively, to generate horizontal borders inside the image.  Each of
-these options needs an integer value <i>pixels</i> that determines the
-average distance of the interior border to the related edge of the
-image.  You may combine the <b>-left</b>, <b>-right</b>, <b>-top</b>,
-and <b>-bottom</b> options to generate an image with more than one
-border.  The algorithm ensures that you can concatenate two images
-produced with the same (i.e. <b>-left</b>) value without dislocations.
-
-<p>You specify the dimensions of the generated image with the
-<b>-width</b> and <b>-height</b> options.
-
-<p>Use the <b>-bg</b> and <b>-fg</b> options to set the background
-(margin) color and the foreground (interior) color, respectively.  If
-you don't specify any of the <b>-left</b>, <b>-right</b>, <b>-top</b>,
-and <b>-bottom</b> options, all pixels are set to foreground color.
-The defaults are white foreground and black background.
+<p>Use the options <b>-left</b> or <b>-right</b>, respectively, to make
+vertical borders, and <b>-top</b> or <b>-bottom</b>, respectively, to generate
+horizontal borders inside the image.  The value of each of these options is
+the minimum width of the border on that edge.  Beyond that minimum, the width
+at any given location on that edge is random, varying along the edge in a
+fractal kind of way.
 
+  
 <p>Use the <b>-var</b> option to control the "raggedness" of
-the border.  The less its value is the smoother the border is.  You
+the border.  The lower its value, the smoother the border is.  You
 can initialize the pseudo-random generator with the <b>-init</b>
 option.
 
@@ -88,51 +79,46 @@ Common Options</a>), <b>ppmrough</b> recognizes the following
 command line options:
 
 <dl compact>
-<dt><b>-left=</b><i>pixels</i>
-
-<dd> Specifies the mean distance of the border from the left margin
-(default: no border).
 
-<dt><b>-right=</b><i>pixels</i>
+<dt><b>-width=</b><i>pixels</i>
 
-<dd>Specifies the mean distance of the border from the right margin
-(default: no border).
+<dd>This specifies the width of the image in pixels (default: 100).
 
-<dt><b>-top=</b><i>pixels</i>
+<dt><b>-height=</b><i>pixels</i>
 
-<dd>Specifies the mean distance of the border from the top margin
-(default: no border).
+<dd>This specifies the height of the image in pixels (default: 100).
 
+<dt><b>-left=</b><i>pixels</i>
+<dt><b>-right=</b><i>pixels</i>
+<dt><b>-top=</b><i>pixels</i>
 <dt><b>-bottom=</b><i>pixels</i>
 
-<dd>Specifies the mean distance of the border from the bottom margin
-(default: no border).
-
-<dt><b>-width=</b><i>pixels</i>
-
-<dd>Specifies the width of the image (default: 100).
-
-<dt><b>-height=</b><i>pixels</i>
-
-<dd>Specifies the height of the image (default: 100).
+<dd>This option causes the program to create a left, right, top, or bottom
+border, respectively, at least <i>pixels</i> pixels wide, varying randomly
+beyond that.  You may specify any combination of these.
 
 <dt><b>-bg=</b><i>colorspec</i>
 
-<dd>Background color.  <i>colorspec</i> is as described for the
+<dd>This is the background color, i.e. the color of the
+borders.  <i>colorspec</i> is as described for the
 <a href="libnetpbm_image.html#colorname">argument of the
 <b>pnm_parsecolor()</b> library routine</a>.  Default is black.
 
 <dt><b>-fg=</b><i>color</i>
 
-<dd>Foreground color.  <i>colorspec</i> is as described for the
+<dd>This specifies the foreground color, i.e. the color of the center of the
+mage -- everything but the borders.  <i>colorspec</i> is as described for the
 <a href="libnetpbm_image.html#colorname">argument of the
 <b>pnm_parsecolor()</b> library routine</a>.  Default is white.
 
 <dt><b>-var=</b><i>pixels</i>
 
-<dd> Specifies the variance of the ragged border (default: 10). Must
-be a positive integer.  Set <i>pixels</i> to 1 to get a straight
-border.
+<dd>This specifies how ragged the borders are -- how much and how quickly its
+width varies along the image edge.  Its specific meaning is complex, but the
+larger it is, the more the border varies.  Zero means it does not vary at all
+-- the edge of the foreground is straight.
+
+<p>This must be a nonnegative integer.  The default is 10.
 
 <dt><b>-randomseed=</b><i>seed</i>