200 likes | 341 Views
CS 551/651: Antialiasing Wrap-up. David Luebke cs551dl@cs.virginia.edu http://www.cs.virginia.edu/~cs551dl. Administrivia. Hand in Assignment 1 Hand out Assignment 2 Sampling strategies in RSRT Due Tuesday March 9 Read Sections 10.1, 10.4. Recap: Antialiasing Strategies. Prefiltering
E N D
CS 551/651: Antialiasing Wrap-up David Luebke cs551dl@cs.virginia.edu http://www.cs.virginia.edu/~cs551dl David Luebke 1/19/99
Administrivia • Hand in Assignment 1 • Hand out Assignment 2 • Sampling strategies in RSRT • Due Tuesday March 9 • Read Sections 10.1, 10.4 David Luebke 1/19/99
Recap: Antialiasing Strategies • Prefiltering • Supersampling • A-Buffer • Adaptive supersampling • Stochastic supersampling David Luebke 1/19/99
Recap: Nonuniform Supersampling • To be correct, need to modify filtering step: David Luebke 1/19/99
Recap: Nonuniform Supersampling • Approximate answer: weighted average filter • Correct answer: multistage filtering • Real-world answer: ignore the problem I(i, j) h(x-i, y-j) I’(x,y)= h(x-i, y-j) David Luebke 1/19/99
Recap: Antialiasing and Texture Mapping • Texture mapping is uniquely harder • Potential for infinite frequencies • Texture mapping is uniquely easier • Textures can be prefiltered David Luebke 1/19/99
Recap: Antialiasing and Texture Mapping • Issue in prefiltering texture is how much texture a pixel filter covers • Simplest prefiltering scheme: MIP-mapping • Assumption: approximate filter size, ignore filter shape • Create a pyramid of texture maps • Each level doubles filter size David Luebke 1/19/99
Recap: Mip-Mapping • Tri-linear mip-mapping • Pixel size depth d • Linearly interpolate colors within 2 levels closest to d • Linearly interpolate color between levels according to d David Luebke 1/19/99
Antialiasing: Mip Mapping • Q: What’s wrong with the mip-map approach to prefiltering texture? • A: Assumes pixel maps to square in texture space • More sophisticated inverse pixel filters (see F&vD p 828): • Summed area tables • Elliptical weighted average filtering David Luebke 1/19/99
Backwards Ray Tracing • Traditional ray tracing traces rays from the eye, through the pixel, off of objects, to the light source • Backwards ray tracing traces rays from the light source, into the scene, into the eye • Why might this be better? David Luebke 1/19/99
Backwards Ray Tracing • Backwards ray tracing can capture: • Indirect illumination • Color bleeding • Caustics • What’s a caustic? • Give some examples • Where do caustics get the name? David Luebke 1/19/99
Backwards Ray Tracing • Usually implies two passes: • Rays are cast from light into scene • Rays are cast from the eye into scene, picking up illumination showered on the scene from the first pass David Luebke 1/19/99
Backwards Ray Tracing • Q: How might these two passes “meet in the middle?” David Luebke 1/19/99
Backwards Ray Tracing • Arvo: illumination mapstile surfaces with regular grids, like texture maps • Shoot rays outward from lights • Every ray hit deposits some of its energy into surface’s illumination map • Ignore first generation hits that directly illuminate surface (Why?) • Eye rays look up indirect illumination using bilinear interpolation David Luebke 1/19/99
Backwards Ray Tracing • Watt & Watt, Plate 34 • Illustrates Arvo’s method of backwards ray tracing using illumination maps • Illustrates a scene with caustics • Related idea: photon maps David Luebke 1/19/99
Distributed Ray Tracing • Distributed ray tracing is an elegant technique that tackles many problems at once • Stochastic ray tracing: distribute rays stochastically across pixel • Distributed ray tracing: distribute rays stochastically across everything David Luebke 1/19/99
Distributed Ray Tracing • Distribute rays stochastically across: • Pixel for antialiasing • Light source for soft shadows • Reflection function for soft (glossy) reflections • Time for motion blur • Lens for depth of field • Cook: 16 rays suffice for all of these David Luebke 1/19/99
Distributed Ray Tracing • Distributed ray tracing is basically a Monte Carlo estimation technique • Practical details: • Use lookup tables (LUTs) for distributing rays across functions • See W&W Figure 10.14 p 263 David Luebke 1/19/99
Advanced Ray Tracing Wrapup • Backwards ray tracing accounts for indirect illumination by considering more general paths from light to eye • Distributed ray tracing uses a Monte Carlo sampling approach to solve many ray-tracing aliasing problems David Luebke 1/19/99
Next Up: Radiosity • Ray tracing: • Models specular reflection easily • Diffuse lighting is more difficult • Radiosity methods explicitly model light as an energy-transfer problem • Models diffuse interreflection easily • Shiny, specular surfaces more difficult David Luebke 1/19/99