CMSC 635 Ray Tracing.

Slides:



Advertisements
Similar presentations
Computer Graphics - Rasterization -
Advertisements

Christian Lauterbach COMP 770, 2/16/2009. Overview  Acceleration structures  Spatial hierarchies  Object hierarchies  Interactive Ray Tracing techniques.
Collisions and Intersections When objects move, test for collision. When projecting surfaces, check for intersections. (Many slides adapted from Amitabh.
CS 352: Computer Graphics Chapter 7: The Rendering Pipeline.
Intersection Testing Chapter 13 Tomas Akenine-Möller Department of Computer Engineering Chalmers University of Technology.
CSE 681 Bounding Volumes. CSE 681 Bounding Volumes Use simple volume enclose object(s) tradeoff for rays where there is extra intersection test for object.
Collision Detection CSCE /60 What is Collision Detection?  Given two geometric objects, determine if they overlap.  Typically, at least one of.
Collision Detection and Resolution Zhi Yuan Course: Introduction to Game Development 11/28/
Computer graphics & visualization Collisions. computer graphics & visualization Simulation and Animation – SS07 Jens Krüger – Computer Graphics and Visualization.
Ray Tracing CMSC 635. Basic idea How many intersections?  Pixels  ~10 3 to ~10 7  Rays per Pixel  1 to ~10  Primitives  ~10 to ~10 7  Every ray.
CSE 872 Dr. Charles B. Owen Advanced Computer Graphics1 Ray Tracing Variants Distributed ray tracing Generalized rays Cone Tracing Beam Tracing Pencil.
Chapter 6: Vertices to Fragments Part 2 E. Angel and D. Shreiner: Interactive Computer Graphics 6E © Addison-Wesley Mohan Sridharan Based on Slides.
18.1 Si31_2001 SI31 Advanced Computer Graphics AGR Lecture 18 Image-based Rendering Light Maps What We Did Not Cover Learning More...
Computer Graphics (Fall 2005) COMS 4160, Lecture 21: Ray Tracing
Ray Casting Ray-Surface Intersections Barycentric Coordinates Reflection and Transmission [Shirley, Ch.9] Ray Tracing Handouts Ray Casting Ray-Surface.
OBBTree: A Hierarchical Structure for Rapid Interference Detection Gottschalk, M. C. Lin and D. ManochaM. C. LinD. Manocha Department of Computer Science,
Foundations of Computer Graphics (Spring 2010) CS 184, Lecture 14: Ray Tracing
Vertices and Fragments III Mohan Sridharan Based on slides created by Edward Angel 1 CS4395: Computer Graphics.
Collision Detection David Johnson Cs6360 – Virtual Reality.
Introduction to 3D Graphics John E. Laird. Basic Issues u Given a internal model of a 3D world, with textures and light sources how do you project it.
Cornell CS465 Fall 2004 Lecture 3© 2004 Steve Marschner 1 Ray Tracing CS 465 Lecture 3.
12/4/2001CS 638, Fall 2001 Today Using separating planes/axes for collision testing Collision detection packages.
1 Speeding Up Ray Tracing Images from Virtual Light Field Project ©Slides Anthony Steed 1999 & Mel Slater 2004.
The Visibility Problem In many environments, most of the primitives (triangles) are not visible most of the time –Architectural walkthroughs, Urban environments.
CSE 381 – Advanced Game Programming Quickhull and GJK.
Collision handling: detection and response
Visibility Culling David Luebke Computer Science Department University of Virginia
David Luebke10/9/2015 CS 551 / 645: Introductory Computer Graphics David Luebke
Real-Time Rendering SPEEDING UP RENDERING Lecture 04 Marina Gavrilova.
Week 13 - Monday.  What did we talk about last time?  Exam 2!  Before that…  Polygonal techniques ▪ Tessellation and triangulation  Triangle strips,
12/4/2001CS 638, Fall 2001 Today Managing large numbers of objects Some special cases.
2 COEN Computer Graphics I Evening’s Goals n Discuss application bottleneck determination n Discuss various optimizations for making programs execute.
1Computer Graphics Implementation II Lecture 16 John Shearer Culture Lab – space 2
Implementation II Ed Angel Professor of Computer Science, Electrical and Computer Engineering, and Media Arts University of New Mexico.
Implementation II.
David Luebke11/26/2015 CS 551 / 645: Introductory Computer Graphics David Luebke
Ray Tracing Fall, Introduction Simple idea  Forward Mapping  Natural phenomenon infinite number of rays from light source to object to viewer.
Ray Tracing II. HW1 Part A due October 10 Camera module Object module –Read from a file –Sphere and Light only Ray tracer module: –No shading. No reflection.
CS559: Computer Graphics Final Review Li Zhang Spring 2010.
Computer Graphics I, Fall 2010 Implementation II.
CS 551/651: Advanced Computer Graphics
David Luebke2/23/2016 CS 551 / 645: Introductory Computer Graphics David Luebke
Ray Tracing Optimizations
David Luebke 3/5/2016 Advanced Computer Graphics Lecture 4: Faster Ray Tracing David Luebke
David Luebke3/12/2016 Advanced Computer Graphics Lecture 3: More Ray Tracing David Luebke
Path/Ray Tracing Examples. Path/Ray Tracing Rendering algorithms that trace photon rays Trace from eye – Where does this photon come from? Trace from.
Ray Tracing Acceleration (1). Acceleration of Ray Tracing Goal: Reduce the number of ray/primitive intersections.
Computer Graphics: Programming, Problem Solving, and Visual Communication Steve Cunningham California State University Stanislaus and Grinnell College.
Computer Graphics Implementation II
Bounding Volume Hierarchies and Spatial Partitioning
CSE 167 [Win 17], Lecture 15: Ray Tracing Ravi Ramamoorthi
CSC418 Computer Graphics Back Faces Visibility Algorithms.
Collision Detection Spring 2004.
Visible-Surface Detection Methods
Bounding Volume Hierarchies and Spatial Partitioning
Modeliranje kompleksnih modelov
3D Object Representations
Parts of these slides are based on
© University of Wisconsin, CS559 Fall 2004
Collision handling: detection and response
Implementation II Ed Angel Professor Emeritus of Computer Science
CS 551 / 645: Introductory Computer Graphics
Introduction to Computer Graphics with WebGL
Collision Detection.
Anti-aliased and accelerated ray tracing
David Johnson Cs6360 – Virtual Reality
Modeliranje kompleksnih modelov
Implementation II Ed Angel Professor Emeritus of Computer Science
Presentation transcript:

CMSC 635 Ray Tracing

Basic idea

Intersection approaches Plug parametric ray into implicit shape Plug parametric shape into implicit ray Solve implicit ray = implicit shape

Making it easier Transform to cannonical ray (0,0,0)–(0,0,1) Transform to cannonical object Ellipsoid to unit sphere at (0,0,0) Compute in stages Polygon plane, then polygon edges Numerical iteration

How many intersections? Pixels ~103 to ~107 Rays per Pixel 1 to ~10 Primitives ~10 to ~107 Every ray vs. every primitive ~104 to ~1015

Speedups Faster intersections Fewer intersections

Fewer intersections Object-based Space-based Image-based

Object: bounding hierarchy Bounding spheres AABB OBB Slabs

Bounding spheres Very fast to intersect Hard to fit Poor fit

AABB Fast to intersect Easy to fit Reasonable fit

OBB Pretty fast to intersect Harder to fit Good fit Eigenvectors of covariance matrix Iterative minimization Good fit

Slabs Families of planes Fast intersection

Space: partitioning Slabs Uniform grid Octtree BSP

Image Coherence Image approximation Light buffer (avoid shadow rays) Pencil tracing/cone tracing Image approximation Truncate ray tree Successive refinement Contrast-driven antialiasing

Algorithmic improvements Object-based Decide ray doesn’t intersect early Space-based Partial order of intersection tests Image-based Ray-to-ray coherence

Faster intersections Precompute and store with object Cache results from previous tests Stop early for reject Postpone expensive operations Reject then normalize If a cheap approximate test exists, do it first Sphere / box / separating axes / … Project to fewer dimensions

Parallel intersections Distribute pixels Distribute rays Distribute objects

Parallel intersections Load balancing Scattered rays, blocks, lines, ray queues Culling Communication costs Database Ray requests Ray results