home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
rtsi.com
/
2014.01.www.rtsi.com.tar
/
www.rtsi.com
/
OS9
/
OSK
/
NETWORK
/
netpbm_docs.lzh
/
NETPBM
/
DOCS
/
pgmcrater.1
< prev
next >
Wrap
Text File
|
1996-11-18
|
5KB
|
169 lines
.TH pgmcrater 1 "15 October 1991"
.IX pgmcrater
.IX fractals
.IX craters
.SH NAME
pgmcrater - create cratered terrain by fractal forgery
.SH SYNOPSIS
.na
.B pgmcrater
'ti 15
.RB [ -number
.IR n ]
.RB [ -height | -ysize
.IR s ]
.RB [ -width | -xsize
.IR s ]
.RB [ -gamma
.IR g ]
.ad
.SH DESCRIPTION
.B pgmcrater
creates a portable graymap which mimics cratered terrain. The graymap
is created by simulating the impact of a given number of craters with
random position and size, then rendering the resulting terrain
elevations based on a light source shining from one side of the
screen. The size distribution of the craters is based on a power law
which results in many more small craters than large ones. The number
of craters of a given size varies as the reciprocal of the area as
described on pages 31 and 32 of Peitgen and Saupe[1]; cratered bodies
in the Solar System are observed to obey this relationship. The
formula used to obtain crater radii governed by this law from a
uniformly distributed pseudorandom sequence was developed by Rudy
Rucker.
.PP
High resolution images with large numbers of craters often benefit
from being piped through
.BR pnmsmooth .
The averaging performed by this process eliminates some of the jagged
pixels and lends a mellow ``telescopic image'' feel to the overall
picture.
.SH OPTIONS
.TP 10
.BI -number " n"
Causes
.I n
craters to be generated. If no
.B -number
specification is given, 50000 craters will be generated. Don't expect
to see them all! For every large crater there are many, many more
tiny ones which tend simply to erode the landscape. In general, the
more craters you specify the more realistic the result; ideally you
want the entire terrain to have been extensively turned over again and
again by cratering. High resolution images containing five to ten
million craters are stunning but take quite a while to create.
.TP
.BI -height " height"
Sets the height of the generated image to
.I height
pixels. The default height is 256 pixels.
.TP
.BI -width " width"
Sets the width of the generated image to
.I width
pixels. The default width is 256 pixels.
.TP
.BI -xsize " width"
Sets the width of the generated image to
.I width
pixels. The default width is 256 pixels.
.TP
.BI -ysize " height"
Sets the height of the generated image to
.I height
pixels. The default height is 256 pixels.
.TP
.BI -gamma " factor"
The specified
.I factor
is used to gamma correct the graymap in the same manner as performed
by
.BR pnmgamma .
The default value is 1.0, which results in a medium contrast image.
Values larger than 1 lighten the image and reduce contrast, while
values less than 1 darken the image, increasing contrast.
.PP
All flags can be abbreviated to their shortest unique prefix.
.SH BUGS
The
.B -gamma
option isn't really necessary since you can achieve the same
effect by piping the output from
.B pgmcrater
through
.BR pnmgamma .
However,
.B pgmcrater
performs an internal gamma map anyway in the process of rendering the
elevation array into a graymap, so there's no additional overhead in
allowing a user-specified gamma.
.PP
Real craters have two distinct morphologies.
.B pgmcrater
simulates only small craters, which are hemispherical in shape
(regardless of the incidence angle of the impacting body, as long as the
velocity is sufficiently high). Large craters, such as Copernicus and
Tycho on the Moon, have a ``walled plain'' shape with a cross-section more
like:
.nf
.ne 2
.cs R 18
/\\ /\\
.br
_____/ \\____________/\\____________/ \\_____
.cs R
.fi
.ss 12
Larger craters should really use this profile, including the central
peak, and totally obliterate the pre-existing terrain.
.SH "SEE ALSO"
.PD
.BR pgm (5),
.BR pnmgamma (1),
.BR pnmsmooth (1)
.TP 5
[1]
Peitgen, H.-O., and Saupe, D. eds., The Science Of Fractal Images,
New York: Springer Verlag, 1988.
.ne 10
.SH AUTHOR
.RS 5
.nf
John Walker
Autodesk SA
Avenue des Champs-Montants 14b
CH-2074 MARIN
Suisse/Schweiz/Svizzera/Svizra/Switzerland
.PD 0
.TP 9
Usenet:
kelvin@Autodesk.com
.TP
Fax:
038/33 88 15
.TP
Voice:
038/33 76 33
.fi
.RE
.PD
.PP
Permission to use, copy, modify, and distribute this software and its
documentation for any purpose and without fee is hereby granted,
without any conditions or restrictions. This software is provided ``as
is'' without express or implied warranty.
.PP
.B PLUGWARE!
If you like this kind of stuff, you may also enjoy ``James Gleick's
Chaos--The Software'' for MS-DOS, available for $59.95 from your
local software store or directly from Autodesk, Inc., Attn: Science
Series, 2320 Marinship Way, Sausalito, CA 94965, USA. Telephone:
(800) 688-2344 toll-free or, outside the U.S. (415) 332-2344 Ext
4886. Fax: (415) 289-4718. ``Chaos--The Software'' includes a more
comprehensive fractal forgery generator which creates
three-dimensional landscapes as well as clouds and planets, plus five
more modules which explore other aspects of Chaos. The user guide of
more than 200 pages includes an introduction by James Gleick and
detailed explanations by Rudy Rucker of the mathematics and algorithms
used by each program.