For this assignment, write an OpenGL program that can display a 3-D object
in various non-photorealistic styles, in real-time.
Also turn in animation created with this program.
You are to work individually on this assignment.
Tips
The following are tips, not requirements.
-
There's no starter code for this assignment.
You could work from your assignment 2 code, perhaps.
-
It's OK if your program synthesizes geometry (e.g. subdivision surface,
fractal, ...).
-
Silhouette edges can be found in (at least) two ways:
(1) 2-D post-process on image, looking for depth discontinuities,
or (2) check all polygon edges to see if one adjacent face is front-facing
while the other is backfacing, or if it's a boundary edge (only one adjacent
face).
The latter method is probably faster.
If using that approach, make sure your silhouette edges are drawn
into the z-buffer so they're properly occluded by surfaces in front.
You'll probably want to use glPolygonOffset().
-
Tips on 3-D silhouette-finding.
-
Pointillist effects can be done in (at least) two ways:
(1) 2-D post-process, where brushstrokes are (more or less) stationary with
respect to screen space,
or (2) drawing brushstrokes in 3-D as z-buffered splats or sprites.
With either method, each brushstroke can be a square (ugly -- points off),
circle, or any other shape, perhaps antialiased or drawn with a soft matte.
It could even be a photograph or sketch of a single brushstroke.
You'll have to tune the number and size of brushstrokes
to avoid excessive gaps or overlaps.
-
For better temporal coherence:
if your pointillist method uses random numbers, you can make them
repeatable by, for example, using vertex numbers or edge numbers and
hashing them for lookup in an array of psuedo-random numbers.
-
If generating animation by hand (rotate object, save image, repeat)
the resulting motion can be
jerky unless you're very smooth and consistent over time.
To reduce this problem, you could make your interactive controls affect
not the value of parameters (rotation angle, translation, ...) but their
first derivatives. That way, the camera/rotation changes will have
momentum, and things will continue to move linearly unless you change
the settings.
Or you could simply low pass filter (temporally blur) the mouse input.
Non-Photorealistic Rendering Examples
We suggest you look at the pictures at the following web sites for
visual inspiration or for optimization tips.
Reading the papers below in full is not necessary to do this assignment,
but you might find them interesting.
-
Craig Reynolds' collection of NPR links
great set of links here
-
http://www.dcs.shef.ac.uk/~dan/images.html
-
cartoon:
http://www.coolpowers.com/products/toonuppro/gallery.html
-
http://www.davidgould.com/Gallery.htm,
this links demonstrate the different rendering styles for NPR.
-
Paul Haeberli's Impressionist
java program
based on his excellent SIGGRAPH 90 paper
Paint By Numbers: Abstract Image Representations
(see Reynolds' links above)
-
Jeff Lander's articles on Cartoon Rendering
-
Ramesh Raskar's silhouette edges,
nice images
-
Real-Time Hatching,
Emil Praun, Hugues Hoppe, Matthew Webb, Adam Finkelstein,
SIGGRAPH '01.
Hatching (parallel lines for shading) in real time,
using texture mapping.
-
Illustrating smooth surfaces,
Aaron Hertzmann,
Denis Zorin,
SIGGRAPH '00.
We recommend this paper for its short section on fast (sublinear)
computation of silhouette edges on a polygon model.
That is, it's not necessary to visit all edges in order to find the
silhouette edges!
Note that use of the simple, linear-time algorithm is probably
good enough for this assignment, however.
Paper also describes a slow but good algorithm for cross-hatching.
-
Pointillism carried to its extreme: polka dot style.
A blobby model
(PS)
by Paul Heckbert and Andy Witkin, SIGGRAPH '94.
-
Video Gogh image processing software
from RE:Vision Effects
-
A Non-Photorealistic Lighting Model For Automatic Technical Illustration,
by Amy Gooch, Bruce Gooch, Peter Shirley and Elaine Cohen.
SIGGRAPH 98.
Modified Phong Model.
-
Real-Time Non-photorealistic Rendering,
by Lee Markosian,
Michael A. Kowalski, Samuel J. Trychin, Lubomir Bourdev, Daniel
Goldstein, and John F. Hughes.
SIGGRAPH 97.
Trades accuracy and detail for speed,
uses a method for determining visible lines and surfaces which is a
modification of Appel's hidden-line algorithm.
Fast, approximate, stochastic silhouette algorithm.
-
SIGGRAPH papers online:
2001 ,
2000 ,
1999 ,
Traditional Paintings
-
Paintings.
See, e.g. Impressionism.
You might want to check out the artists Seurat, Signac, Monet, and Van Gogh.
-
Go to the
Light
exhibit currently on display at the Carnegie Museum of Art
down Forbes Ave.
(see
announcement on 463 web page)
Grading Criteria
Out of 12 points:
-
4 points: cartoon style (we'll check for speed & image quality)
-
4 points: pointillist style (ditto)
-
4 points: nice animation
Extra credit for real-time
-
halftoning (use OpenGL stencil buffer?)
-
hatching
-
Kandinsky, Mondrian, or Matisse, ...
-
photomosaics.
This is just a variation on the pointillist idea above
where small pictures are used as brushstrokes, and a picture is found whose
color (and frequency content?) matches that desired.
You could scour the web, collect a few thousand pictures,
and zoom them down.
A few sources for images:
ditto.com ,
astronomy pic of day ,
Yahoo picture gallery ,
Getty Museum ,
Photo Bank ,
animal pictures .
The .list files in
the a4/pix directory
contain lists of pictures found in a breadth-first traversal of
those web pages to a depth of 2 or 3.
-
interactive placement of brushstrokes using cursor
-
characters (glyphs from a font) as brushstrokes
-
Postscript for high resolution output
(600 dpi on 10 inch page means 6000 pixel resolution!)
-
other cool ideas
Change log:
16 Apr. 2001: revision 1
18 Apr. 2001: minor clarifications & photo source list added
26 Apr. 2001: added silhouette-finding tips
30 Apr. 2001: resolution should be 640x480 or higher
3 May 2001: animation deadline extended by 24 hrs to Thu night.
15-463, Computer Graphics 2
Paul Heckbert