GR2 Advanced Computer Graphics AGR

Slides:



Advertisements
Similar presentations
Visible-Surface Detection(identification)
Advertisements

Advanced Piloting Cruise Plot.
Chapter 1 The Study of Body Function Image PowerPoint
Jeopardy Q 1 Q 6 Q 11 Q 16 Q 21 Q 2 Q 7 Q 12 Q 17 Q 22 Q 3 Q 8 Q 13
Jeopardy Q 1 Q 6 Q 11 Q 16 Q 21 Q 2 Q 7 Q 12 Q 17 Q 22 Q 3 Q 8 Q 13
Title Subtitle.
My Alphabet Book abcdefghijklm nopqrstuvwxyz.
DIVIDING INTEGERS 1. IF THE SIGNS ARE THE SAME THE ANSWER IS POSITIVE 2. IF THE SIGNS ARE DIFFERENT THE ANSWER IS NEGATIVE.
Polygon Scan Conversion – 11b
13.1 Vis_2003 Data Visualization Lecture 13 Visualization of Very Large Datasets.
1GR2-00 GR2 Advanced Computer Graphics AGR Lecture 17 Radiosity - Conclusion Non-PhotoRealistic Rendering.
1GR2-00 GR2 Advanced Computer Graphics AGR Lecture 9 Adding Realism Through Texture.
1GR2-00 GR2 Advanced Computer Graphics AGR Ken Brodlie Lecture 1 - Overview.
1GR2-00 GR2 Advanced Computer Graphics AGR Lecture 18 Image-based Rendering Final Review of Rendering What We Did Not Cover Learning More...
GR2 Advanced Computer Graphics AGR
GR2 Advanced Computer Graphics AGR
GR2 Advanced Computer Graphics AGR
GR2 Advanced Computer Graphics AGR
SI23 Introduction to Computer Graphics
SI23 Introduction to Computer Graphics
GR2 Advanced Computer Graphics AGR
1GR2-00 GR2 Advanced Computer Graphics AGR Lecture 16 Radiosity - continued.
16.1 Si23_03 SI23 Introduction to Computer Graphics Lecture 16 – Some Special Rendering Effects.
7.1 si31_2001 SI31 Advanced Computer Graphics AGR Lecture 7 Polygon Shading Techniques.
5.1 si31_2001 SI31 Advanced Computer Graphics AGR Lecture 5 A Simple Reflection Model.
9.1si31_2001 SI31 Advanced Computer Graphics AGR Lecture 9 Adding Realism Through Texture.
SI31 Advanced Computer Graphics AGR
8.1si31_2001 SI31 Advanced Computer Graphics AGR Lecture 8 Polygon Rendering.
13.1 si31_2001 SI31 Advanced Computer Graphics AGR Lecture 13 An Introduction to Ray Tracing.
Randomized Algorithms Randomized Algorithms CS648 1.
Data Structures ADT List
ABC Technology Project
Plane wave reflection and transmission
1 Undirected Breadth First Search F A BCG DE H 2 F A BCG DE H Queue: A get Undiscovered Fringe Finished Active 0 distance from A visit(A)
VOORBLAD.
1 05/10/2014 Computer Graphics Lecture 10 Global Illumination 1: Ray Tracing and Radiosity Taku Komura.
#1UNIT C Describes a material which allows light to pass through easily.
© 2012 National Heart Foundation of Australia. Slide 2.
Computer Graphics Inf4/MSc 1 Computer Graphics Lecture 4 View Projection Taku Komura.
Addition 1’s to 20.
25 seconds left…...
Week 1.
Fisica Generale - Alan Giambattista, Betty McCarty Richardson Copyright © 2008 – The McGraw-Hill Companies s.r.l. 1 Chapter 23: Reflection and Refraction.
We will resume in: 25 Minutes.
PSSA Preparation.
13- 1 Chapter 13: Color Processing 。 Color: An important descriptor of the world 。 The world is itself colorless 。 Color is caused by the vision system.
Technische Universität München Computer Graphics SS 2014 Graphics Effects Rüdiger Westermann Lehrstuhl für Computer Graphik und Visualisierung.
Christian Lauterbach COMP 770, 2/16/2009. Overview  Acceleration structures  Spatial hierarchies  Object hierarchies  Interactive Ray Tracing techniques.
May Visible Surface Detection Shmuel Wimer Bar Ilan Univ., Eng. Faculty Technion, EE Faculty.
Illumination Model & Surface-rendering Method 박 경 와.
Lecture 8 Advanced Rendering – Ray Tracing, Radiosity & NPR.
Ray Tracing Primer Ref: SIGGRAPH HyperGraphHyperGraph.
Spatial Data Structures Jason Goffeney, 4/26/2006 from Real Time Rendering.
1 Speeding Up Ray Tracing Images from Virtual Light Field Project ©Slides Anthony Steed 1999 & Mel Slater 2004.
CS 376 Introduction to Computer Graphics 04 / 16 / 2007 Instructor: Michael Eckmann.
Ray Tracing Chapter CAP4730: Computational Structures in Computer Graphics.
Visible-Surface Detection Jehee Lee Seoul National University.
Recursion and Data Structures in Computer Graphics Ray Tracing 1.
第五课 Ray Tracing. Overview of the Section Why Ray Tracing? What is Ray Tracing? How to tracing rays? How to accelerating ray-tracing?
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.
Bounding Volume Hierarchy. The space within the scene is divided into a grid. When a ray travels through a scene, it only passes a few boxes within the.
Maths & Technologies for Games Spatial Partitioning 2
Ray Tracing Optimizations
David Luebke 3/5/2016 Advanced Computer Graphics Lecture 4: Faster Ray Tracing David Luebke
CSE 681 Introduction to Ray Tracing. CSE 681 Ray Tracing Shoot a ray through each pixel; Find first object intersected by ray. Image plane Eye Compute.
David Luebke3/12/2016 Advanced Computer Graphics Lecture 3: More Ray Tracing David Luebke
Ray Tracing Acceleration (3)
GR2 Advanced Computer Graphics AGR
Presentation transcript:

GR2 Advanced Computer Graphics AGR Lecture 14 Improving the Efficiency of Ray Tracing Light Source Effects

Advantages and Disadvantages of Ray Tracing Ray tracing is attractive because shadows, reflections, refractions are easily incorporated Ray tracing is expensive because the cost of computing ray-object intersections is very high This part of the lecture looks at efficiency issues in ray tracing

Ray Tracing - A Reminder pixel positions on view plane camera The intensity calculation is now: I = I local + k r * I reflected + k t * I transmitted I reflected and I transmitted are calculated recursively

Adaptive Tree Depth Control Basic algorithm follows rays until they leave the scene (or hit diffuse surface) - in theory the tree depth can then be considerable In practice, it is not usually necessary to trace rays to any great depth As tree formed, a running product is kept of transmission and reflection coefficients this product attenuates all intensities lower in tree once product less than threshold, branch is stopped

Bounding Volumes Enclose groups of objects in a simple bounding volume sphere or box Test for intersection against bounding volume if none, then ray does not intersect objects within if intersection occurs, test against each object in turn Idea can be extended to hierarchies of bounding volumes (usually boxes)

Spatial Subdivision Idea: divide space into subregions, noting objects in each subregion termed ‘spatial subdivision’ or ‘spatial coherence’ Calculation changes from: for each object or bounding box, find ray intersection to as ray proceeds through space, are there any objects in the current subregion? if yes, calculate intersections; if not, move on find next subregion entered by the ray

How do we Subdivide Space One idea is octree partitioning We illustrate in 2D - known as quadtree First divide space into four regions Count number of objects in each region If a region contains an object, subdivide again Continue to a specified level of subdivision

Octree A tree structure emerges, with the nodes at the leaves of the tree containing (hopefully) a small number of objects, or empty. This is quadtree - in 3D we subdivide cube into 8 each time, getting an octree

Ray Tracing through Octree We trace ray from subregion to subregion, only doing intersection tests for the small number of objects in the subregion. Find region corresponding to start point. Test ray for intersections with any objects. If none, find next region - by calculating intersection with region boundaries. Advance a short way into next region - say to (x,y,z) Find region which includes (x,y,z) and continue.

Finding Region Containing (x,y,z) We use octree itself to locate region. Starting at top, a simple test determines in which of eight (4 for quadtree) regions the point (x,y,z) lies. Proceed down tree until leaf node reached.

Binary Space Partitioning An alternative to octrees is just to split into two at each step separating plane typically chosen to divide space into regions of equal complexity Known as Binary Space Partitioning, or BSP, trees

Octrees versus BSP trees good for scenes where density of objects varies widely possible to have small objects in large regions stepping from region to region slow because trees tend to be unbalanced BSP trees: depth of tree smaller because tree balanced memory costs lower void areas smaller

Ray Tracing Software Persistence Of Vision Ray Tracer (POV-RAY) is public domain ray tracing software Download from: http://www.povray.org

More Teapots! The POVRAY version

POVLAB modeller

Lecture 14 Part 2 Light Source Effects

Light Source Sequence of Images The following sequence of images were created by Alan Watt of University of Sheffield They illustrate effects of different light sources in a scene

Ambient Light Only

Camera Light Source Light source at camera only. Note no shadows.

Distant Light Source Light rays parallel to each other Note shadows

Point Light Source Point light source close to object, in same direction as distant source in previous picture. Note shadows are different.

Spotlight Spotlight in same position as previous point light. Cone angle is 30 deg. Note cone of influence of the light, and the hard shadow.

Spotlight - Soft Shadows Softer shadow obtained by having a gradual drop-off of intensity at edge of cone (here over last 5 deg)

Effect of Distance - No Attenuation Here there is no attenuation of light over distance

Effect of Distance - Attenuation Intensity is attenuated by 1/distance

Effect of Distance - Attenuation Here the attenuation factor is 1/(distance)2

Fog Intensity of fog increases linearly with depth. How is this achieved?