Standard Procedural Databases
by Eric Haines et al.
click on an image to see a full size rendering
(rendered with POV-Ray 3.1)
This is the code described in:
Eric Haines, "A Proposal for Standard Graphics Environments," IEEE Computer Graphics and Applications, 7(11), Nov. 1987, p. 3-5.
You can download the latest version of the SPD
(currently 3.14), and also view
the original IEEE CG&A article from Nov. 1987. The code is on Github.
This software package is not copyrighted and can be used freely. All source
is in K&R vanilla C (though ANSI headers can be enabled) and has been used on
For a newer set of more realistic environments for benchmarking ray tracers
(or renderers in general), see BART:
A Benchmark for Animated Ray Tracing. The focus is software that generates
an animated set of frames for a ray tracer to render. These scenes use an NFF-like
language (AFF), and the authors provide a number of tools for parsing and visualization.
This software is meant to act as a set of basic test images for ray tracing
algorithms. The programs generate databases of objects which are fairly
familiar and "standard" to the graphics community, such as the teapot, a
fractal mountain, a tree, a recursively built tetrahedral structure, etc. I
originally created them for my own testing of ray tracing efficiency schemes.
Since their first release other researchers have used them to test new
algorithms. In this way, research on algorithmic improvements can be compared
in a more standardized fashion. If one researcher ray-traces a car, another a
tree, the question arises, "How many cars to the tree?" With these databases
we may be comparing oranges and apples, but it's better than comparing oranges
Using these statistics
along with the same scenes allows us to compare results in a more meaningful
Another interesting use for the SPD has been noted: debugging. By
comparing the images and the statistics with the output of your own ray tracer,
you can detect program errors. For example, "mount" is useful for checking if
refraction rays are generated correctly, and "balls" (a.k.a. "sphereflake")
can check for the correctness of eye and reflection rays.
The images for these databases and other information about them can be
found in A
Proposal for Standard Graphics Environments, IEEE Computer
Graphics and Applications, vol. 7, no. 11, November 1987, pp. 3-5. See
IEEE CG&A, vol. 8, no. 1, January 1988, p. 18 for the correct image of
the tree database (the only difference is that the sky is blue, not orange).
The teapot database was added later.
The Neutral File Format (NFF) is the default output
format from SPD programs. This format is trivial to parse (if you can use sscanf,
you can parse it), and each type of object is defined in human terms (e.g. a
cone is defined by two endpoints and radii). The basic shapes supported are
polygon and polygon patch (normal per vertex), cylinder, cone, and sphere. Note
that there are primitives supported within the SPD which are not part of NFF,
e.g. heightfield, NURBS, and torus, so more elaborate programs can be written.
If a format does not support a given primitive, the primitive is tessellated
and output as polygons.
Ares Lagae has written libnff,
a modern C++ library for parsing NFF that also supports conversion to Wavefront OBJ.
Other output formats are
Alexander Enzmann receives most of the credit for creating the various
file format output routines, along with many others who contributed.
POV-Ray 2.0 to 2.2
Polyray 1.4 to 1.6
Art 2.3 (from Vort)
AutoCAD DXF [object data only]
Wavefront OBJ format (polygons only)
RenderWare RWX script file
There are also reader programs for the various formats. Currently the
following formats can be read and converted:
This makes the NFF format a nice, simple language for quickly creating
models (whether by hand or by program), as any NFF file can be converted to many
different formats. Warnings:
DXF (just 3DFACEs)
The conversions tend to be verbose in many cases (e.g. there is currently
no code in place to group polygons of the same material into polygon
mesh primitives used in some formats).
No real tessellation of polygons is done when needed for conversion,
all that happens are that polygon fans are created.
You might find the images you obtain are mirror reversed with some formats
(e.g. VRML 2.0 files).
Gems V code distribution has a simple z-buffer renderer by Raghu
Karinthi, using NFF as the input language.
On hashing: a sore point in mount.c, the fractal mountain generator, has been
its hashing function. Mark VandeWettering has provided a great hashing function
by Bob Jenkins.
To show what a difference it makes, check out images of models made with the
original hash function with a large size factor,
replacement hash function I wrote (still no cigar),
Jenkins' hash function.
For more information on the SPD, see the README.txt file included in the
On some (all?) versions of gcc on Linux, the following correction to the code
libinf.c, line 33:
FILE *gOutfile = stdout;
FILE *gOutfile = NULL;
Research Works using SPD
Timing comparisons for the various scenes using a wide variety of free software
ray tracers are summarized in The Ray Tracing News, 3(1)
Here are some research works which have used the SPD to benchmark their ray tracers
(please let me know of others; you can always search
Google Scholar for more):
- Kay, Timothy L. and James T. Kajiya, "Ray Tracing Complex Scenes," Computer
Graphics (SIGGRAPH '86 Proceedings), 20(4), Aug. 1986, p. 269-78.
- Arvo, James and David Kirk, "Fast Ray Tracing by Ray Classification," Computer
Graphics (SIGGRAPH '87 Proceedings) 21(4), July 1987, p. 55-64.
Also in Tutorial: Computer Graphics: Image Synthesis, Computer Society Press,
Washington, 1988, pp. 196-205. Predates SPD, uses recursive tetrahedron.
- Subramanian, K.R., "Fast Ray Tracing Using K-D Trees," Master's Thesis,
Dept. of Computer Sciences, Univ. of Texas at Austin, Dec. 1987. Uses balls,
- Fussell, Donald and K.R. Subramanian "Fast Ray Tracing Using K-D Trees,"
Technical Report TR-88-07, Dept. of Computer Sciences, Univ. of Texas at Austin
March 1988. Uses balls, tetra, tree.
- Salmon, John and Jeffrey Goldsmith "A Hypercube Ray-Tracer," Proceedings
of the Third Conference on Hypercube Computers and Applications , 1988.
Uses balls and mountain.
- Bouatouch, Kadi and Thierry Priol, "Parallel Space Tracing: An Experience
on an iPSC Hypercube," ed. N. Magnenat-Thalmann and D. Thalmann, New Trends
in Computer Graphics (Proceedings of CG International '88), Springer-Verlag,
New York, 1988, p. 170-87. Uses balls.
- Priol, Thierry and Kadi Bouatouch, "Experimenting with a Parallel Ray-Tracing
Algorithm on a Hypercube Machine," Eurographics '88, Elsevier Science
Publishers, Amsterdam, North-Holland, Sept. 1988, p. 243-59. Uses balls.
- Devillers, Olivier, "The Macro-Regions: an Efficient Space Subdivision
Structure for Ray Tracing," Eurographics '89, Elsevier Science Publishers,
Amsterdam, North-Holland, Sept. 1989, p. 27-38, 541. (revised version of Technical
Report 88-13, Laboratoire d'Informatique de l'Ecole Normale Superieure, Paris,
France, Nov. 1988). Uses balls, tetra.
- Priol, Thierry and Kadi Bouatouch, "Static Load Balancing for a Parallel
Ray Tracing on a MIMD Hypercube," The Visual Computer, 5(1/2),
March 1989, p. 109-19. Uses balls.
- Green, Stuart A. and D.J. Paddon, "Exploiting Coherence for Multiprocessor
Ray Tracing," IEEE Computer Graphics and Applications, 9(6),
Nov. 1989, p. 12-26. Uses balls, mount, rings, tetra.
- Green, Stuart A. and D.J. Paddon, "A Highly Flexible Multiprocessor Solution
for Ray Tracing," The Visual Computer, 6(2), March 1990, p.
62-73. Uses balls, mount, rings, tetra.
- Dauenhauer, David Elliot and Sudhanshu Kumar Semwal, "Approximate Ray Tracing,"
Proceedings of Graphics Interface '90, Canadian Information Processing
Society, Toronto, Ontario, May 1990, p. 75-82. Uses balls, gears, tetra.
- Badouel, Didier, Kadi Bouatouch, Thierry Priol, "Ray Tracing on Distributed
Memory Parallel Computers: Strategies for Distributing Computations and Data,"
SIGGRAPH '90 Parallel Algorithms and Architecture for 3D Image Generation
course notes, 1990. Uses mountain, rings, teapot, tetra.
- Spackman, John, "Scene Decompositions for Accelerated Ray Tracing".
Ph.D. Thesis, The University of Bath, UK, 1990.
Available as Bath Computer Science Technical Report 90/33.
- Green, Stuart A., Parallel Processing for Computer Graphics, MIT
Press/Pitman Publishing, Cambridge, Mass./London, 1991. Uses balls, mount,
- Subramanian, K.R. and Donald S. Fussell, "Automatic Termination Criteria
for Ray Tracing Hierarchies," Proceedings of Graphics Interface '91,
Canadian Information Processing Society, Toronto, Ontario, June 1991, p. 93-100.
Uses balls, tetra.
- Spackman, John N., "The SMART Navigation of a Ray Through an Oct-tree,"
Computers and Graphics, vol. 15, no. 2, June 1991, p. 185-194. Code for
the ray tracer is available.
- Fournier, Alain and Pierre Poulin, "A Ray Tracing Accelerator Based on
a Hierarchy of 1D Sorted Lists," Proceedings of Graphics Interface '93,
Canadian Information Processing Society, Toronto, Ontario, May 1993, p. 53-61.
Uses balls, gears, tetra, tree.
- Simiakakis, George, and A. Day, "Five-dimensional Adaptive Subdivision
for Ray Tracing," Computer Graphics Forum, 13(2), June 1994,
p. 133-140. Uses balls, gears, mount, teapot, tetra, tree.
- Matthew Quail, "Space-Time
Ray-Tracing using Ray Classification," Thesis project for B.S. with Honours, Dept. of Computing,
School of Maths, Physics, Computing and Electronics, Macquarie University.
- Klimaszewski, Krzysztof and Thomas W. Sederberg, "Faster Ray Tracing Using
Adaptive Grids," IEEE Computer Graphics and Applications 17(1),
Jan/Feb 1997, p. 42-51. Uses balls.
- Havran, Vlastimil, Tomas Kopal, Jiri Bittner, and Jiri Zara, "Fast
robust BSP tree traversal algorithm for ray tracing," Journal of Graphics
Tools, 2(4):15-24, 1997. Uses balls, gears, mount, and tetra.
- Nakamaru, Koji and Yoshio Ohno, "Breadth-First Ray Tracing Utilizing Uniform
Spatial Subdivision," IEEE Transactions on Visualization and Computer Graphics,
3(4), Oct-Dec 1997, p. 316-328.
- Havran, Vlastimil, Jiri Bittner, and J. Zara,
"Ray Tracing with Rope Trees,"
Proceedings of SCCG'98 Conference, pp. 130-139, April 1998. Uses 5 normal SPD.
- Sanna, A., P. Montuschi and M. Rossi,
Algorithm for Multiprocessor Ray Tracing,", The Computer Journal, 41(7), pp. 503-516, 1998.
- Müller, Gordon and Dieter W. Fellner, "Hybrid
Scene Structuring with Application to Ray Tracing," Proceedings of
International Conference on Visual Computing (ICVC'99), Goa, India, Feb.
1999, pp. 19-26. Uses balls, lattice, tree.
- Havran, Vlastimil, and Jiri Bittner,
"Rectilinear BSP Trees
for Preferred Ray Sets," Proceedings of SCCG'99 conference, pp. 171-179, April/May 1999.
Uses lattice, rings, tree.
- Havran, Vlastimil and Filip Sixta "Comparison
of Hierarchical Grids," Ray Tracing News, 12(1), June 25, 1999.
Uses all SPD. Additional statistics are available
at this site
- Havran, Vlastimil, "A
Summary of Octree Ray Traversal Algorithms," Ray Tracing News, 12(2),
December 21, 1999. Uses all SPD. Additional
statistics are available at this site
- Havran, Vlastimil, Jan Prikryl, and Werner Purgathofer,
Comparison of Ray-Shooting Efficiency Schemes," Technical Report/TR-186-2-00-14,
Technische Universität Wien,
Institut für Computergraphik und Algorithmen, 4 July 2000. Uses all SPD.
- Havran, Vlastimil, "Heuristic
Ray Shooting Algorithms", Ph.D. Thesis, Czech Technical University,
November 2000. Uses all SPD.
- Koji Nakamaru and Yoshio Ohno. "Enhanced
breadth-first ray tracing," Journal of Graphics Tools, 6(4):13-28,
2001. Uses all SPD. Renderings include up to a billion primitives.
- Simiakakis, George, Th. Theoharis and A. M. Day,
Ray Tracing with 5D Adaptive Subdivision," WSCG 2001 Conference Proceedings, 2001.
Uses 5 normal SPD plus teaport.
- Havran, Vlastimil and Jiri Bittner: "On
Improving KD-Trees for Ray Shooting", Proceedings of WSCG'2002
conference, pp. 209-217, February 2002. Also see Libor Dachs'
ray tracing visualization system.
Last change: October 25, 2015