Project 3 Help Session
CS 348B - Computer Graphics: Image Synthesis Techniques
Spring Quarter, 1999
Frank Crow
Outline
-
Extensions overview
-
Your real object
-
Inventor - a primer
-
The demo
-
The competition
-
The writeup
-
TA's tracing tips
-
FAQ
Assignment overview -- Extending your ray tracer
-
Teams of N=1-3 people, N extensions
-
Adaptive stochastic sampling
-
Strongly suggested (even partially, if not one of your N extensions)
-
Required: Second image - Visualize rays per pixel
-
Bonus: can compensate for non-filtering of textures
-
Extra fun: microscopic view
-
Distribution ray tracing
-
Multiple reflection rays
-
For soft shadows need area or pseudo-area light
-
Texture mapping
-
Strongly suggested
-
Texture coordinates
-
Required primitives: spheres and triangle meshes (and quads)
-
Required modulation: color + one other
-
transparency
-
specularity
-
normal (bump mapping)
-
two different shading models (Cook '84, Perlin '85)
-
Extra fun: mapping via 3D coordinates
-
Extra fun: displacement mapping
-
Optional: procedural
-
Spherical mapping
-
Environment mapping
-
Shading language
-
Shade tree
-
Mix nodes according to textures
-
Extra fun: synthesis (reaction-diffusion,
etc.)
-
Light ray tracing
-
Bidirectional ray tracing (Heckbert, '90)
-
Hybrid ray tracing (Veach, '95)
-
Caustics, specular-to-diffuse transfer
-
Volume rendering
-
Atmospheric attenuation
-
Opacity/color variation over space
-
Extra fun: Hierarchical spatial subdivision
-
Extra fun: Turn on volume rendering only inside an object
-
E.g. amethyst
crystals
-
Can define different functions inside different objects
-
With motion, can see it's 3D, not flat texture
-
Fancy primitives
-
Bicubic patches
-
CSG models
-
Fractals
-
Extra fun: Fur as geometry (don't wait until the last day to render :-)
-
Subsurface scattering
-
Wavelength-dependent effects
-
thin-film interference, fluorescence
A real object
-
Must create it yourself
-
i3dm revisited (demo)
-
everything will be converted to polyset
-
use i3dm_clean! (esp for textures)
-
read docs with "showcase -v /usr/class/cs348b/i3dm/i3dm_help.sc"
-
programs that generate Inventor (such as shell.c)
Inventor - a primer
-
Inventor: a hierarchical modeling language
-
Look at the example .iv files
-
Good reference: "The Inventor Mentor", if you want to know more
-
Example: (/usr/class/cs348b/proj3/tetrahedron.iv)
#Inventor V2.0 ascii
# Create a polyset of a tetrahedron, colored red, green, blue, white
# on the corners. It has per-vertex normals, per-vertex materials.
Separator {
# The position of the 4 vertices
Coordinate3 {
point [
-1 -1 0,
1 -1 0,
0 1 0,
0 0 2
]
}
# The normals for each vertex
NormalBinding { value PER_VERTEX_INDEXED }
Normal {
vector [
-1 -1 -1,
1 -1 -1,
0 1 -1,
0 0 1
]
}
# Texture
# Uncomment the "Texture2" line to make it texture-mapped. Currently,
# it ignores the texture coordinates, since no texture is specified.
# Texture2 { filename "/usr/demos/data/Inventor/defaultTexture.rgb" }
TextureCoordinateBinding { value PER_VERTEX_INDEXED }
TextureCoordinate2 {
point [
0 0,
1 0,
.5 1,
.5 .5
]
}
# Per-vertex materials
MaterialBinding { value PER_VERTEX_INDEXED }
Material {
diffuseColor [
1 0 0,
0 1 0,
0 0 1,
.8 .8 .8,
]
specularColor [
.3 .3 .3,
.3 .3 .3,
.3 .3 .3,
0 0 0
]
}
# The indices of the polygons. "-1" signifies the end of each polygon.
IndexedFaceSet {
coordIndex [
0, 1, 2, -1,
0, 1, 3, -1,
1, 2, 3, -1,
2, 0, 3, -1
]
}
}
# Add a cube, as a base table for the tetrahedron
Separator {
Transform {
translation 0 0 -1
rotation 0 0 1 .57
scaleFactor 5 5 1
# scaleOrientation 0 0 0 1
}
Material {
ambientColor 0 0 0
diffuseColor 0.2 .15 .1
specularColor 0.3 0.3 0.3
emissiveColor 0 0 0
shininess 0.1
transparency 0.0
}
Label {
label "Table bumpmap=woodbmp.ppm texmap=woodtex.ppm"
}
Cube {}
}
The demo
-
15-minute, live demo
-
Bring the real-life object
-
Have precomputed images and animations ready
-
Be prepared to run raytracer on demand - must have imagesize slider
-
Show extensions of your raytracer
-
Tell us all the cool stuff you thought up
-
Encouraged but *not* required to implement more than N extensions - cap
of 100 points.
-
No late days - graded only on what you show Thursday afternoon
The competition
-
Can import existing models, textures, as background objects
-
Must identify any objects you didn't create
-
Self-made objects count a lot more
-
Use fair tools (i3dm, Composer, Sweet Hall workstation tools)
-
Use fair CPU (Roughly equal to a raptor/firebird)
-
Can only use multiprocessors if it doesn't interfere. If you are being
interfered with, send mail.
-
If you want to do multiprocessor raytracing, start NOW!!!
-
Prizes: Siggraph trip, dinner at Il Fornaio, Siggraph videos
-
Aesthetics and composition counts in addition to technical merit!
-
More than N extensions can indeed help
-
Party afterwards (Yes, there will be food :-)
The writeup
-
Due the following Monday
-
No late writeups accepted
-
Include images and animations
-
Either HTML or ASCII text fine
-
Document your choices
TA's Tracing Tips
-
Have fun.
-
Go wild. Be creative.
-
Spend time looking at things. If friends/professors/advisors ask why you're
staring off into space, tell them you're working on your raytracer project.
You are.
-
Don't leave the coding / modeling / raytracing to the end.
-
Do adaptive supersampling. It looks pretty.
-
Form a group. It lets you spend more time on the exotic, exciting stuff.
-
Use images in your raytracing. Color, bump maps, environment maps. Images
are easy to manipulate. Use xpaint to draw them. Use xv to change the color
scaling, smooth them, crop them, etc.
-
Use images in your modeling. Write programs that generate things like height-field
meshes from an image.
-
Start early. Sleep is good.
Questions
lucasp@cs.stanford.edu
with minor modifications by
munzner@cs.stanford.edu
lena@cs.stanford.edu
Copyright © 1998 Marc Levoy
Wednesday, 19-May-1999 05:30:10 PDT