splines
Calculate and display an aggregating particle
- Authored and Contributed by
-
Ronald Joe Record
- Restrictions
- Copyright 1993, 1994 Ronald Joe Record
- History
-
Written using CGI October 5, 1987 by Ron Record (sco!rr)
Rewritten using X11 Apr 20, 1993 by Ron Record (rr@ronrecord.com)
From "Fundamentals of Interactive Computer Graphics" by Foley and Van Dam :
"This terminology traces back to the long flexible strips of metal,
called splines, used by draftsmen to lay out the surfaces of airplanes
and ships. The metal splines, unless severely stressed, also have second-order
continuity."
From "Principles of Interactive Computer Graphics" by Newman and Sproull :
"P. Bezier, of the French firm Regie Renault, pioneered the use of computer
modeling of surfaces in automobile design. His UNISURF system, used by
designers since 1972, has been applied to define the outer panels of several
cars marketed by Renault."
- Description
-
This program uses bouncing balls as control points for generating
cubic curves. Two methods are used to calculate the curve. One, the
Bezier form for defining a cubic, uses n control points with
the tangent vectors at the endpoints being defined by the line
segments between control points. The other, referred to as the
B-spline cubic representation, doesn't pass thru any control points.
In the B-spline, the points where the curve "joins" and their derivatives
are weighted sums of the three immediately adjacent control points.
- Build
-
To build the splines binary, either use the Imakefile or the sample makefile,
Makefile.std. If your system doesn't support prototypes, uncomment the
PROTODEFINE line of the Imakefile.
After modifying the Imakefile appropriately, either use "xmkmf" or "imake"
to create a Makefile. Then just type "make" to compile splines.
The manual page can be formatted by typing "nroff -man splines.man > splines.6X".
- Install
-
To install splines, copy the splines binary to the desired location (the sample
makefile puts it in /usr/local/bin)
Copy the formatted man page to wherever you keep your local doc (i use
/usr/man/cat.LOCAL for imaging software), then add that location
to your MANPATH.
- Productivity
- None
- Safety
- I have used this for years without harm.
- Work Planned
- None
- Documentation
- manual page.
- Verification
-
You can test splines by just invoking it with no arguments.
Some "interesting" ways to run splines are provided as shell scripts
in the params subdirectory of the source and in /usr/skunk/lib/splines.
- Feedback
-
Ideas, comments, additions, deletions, suggestions, bug reports, code review,...
e-mail Ronald Record at rr@ronrecord.com or ...uunet!sco!rr.