DOC PREVIEW
MIT 6 837 - Ray Tracing

This preview shows page 1-2-3-4-5-6-45-46-47-48-49-50-51-91-92-93-94-95-96 out of 96 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 96 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

MIT EECS 6.837, Teller and Durand1MIT EECS 6.837Frédo Durand and Seth TellerSome slides courtesy of Leonard McMillanRay TracingMIT EECS 6.837, Teller and Durand2Administrative• Assignment 4– Due Friday 11 at 5pm– Polygon rasterization– Phong highlight• Office hour this week– Teller & Durand 4-035 Thursday from 4 to 6– Ngan 4 to 7 Thursday W20–Friday • Durand 9-10 in NE43-254• Ngan 11-12 NE43-256• Teller 2:30-3:30 NE43-252MIT EECS 6.837, Teller and Durand3Today: Ray Tracing• And review of Ray Casting with slides with time!Image by Turner WhittedMIT EECS 6.837, Teller and Durand4Today: Ray TracingImages and animation byHenrik WannJensenMIT EECS 6.837, Teller and Durand5References• Shirley Chapter 9• Other specialized books:• Online resourceshttp://www.irtc.org/http://www.acm.org/tog/resources/RTNews/html/http://www.povray.org/http://www.siggraph.org/education/materials/HyperGraph/raytrace/rtrace0.htmhttp://www.siggraph.org/education/materials/HyperGraph/raytrace/rt_java/raytrace.htmlMIT EECS 6.837, Teller and Durand6Overview• Ray casting• Transformations• Ray-Primitive intersection• Advanced ray casting• Ray TracingMIT EECS 6.837, Teller and Durand7Scan Conversion and Visibility• Hidden surfaces eliminated at each pixel– z buffering– Scanline algorithms– Shading computed many times at each pixel– Each pixel stores only constant stateMIT EECS 6.837, Teller and Durand8Limitations of Scan Conversion• Restricted to scan-convertableprimitives– Object polygonalization • Faceting, shading artifacts• Effective resolution hardware dependent (aliasing)• No handling of shadows, reflection, transparency• Problem of overdraw (high depth complexity)• What if there are more triangles than pixels?MIT EECS 6.837, Teller and Durand9Graphics Pipeline Review• Primitives are processed one at a time• All analytic processing early on• Sampling occurs late• Minimal state required (immediate mode rendering)• Processing is forward-mappingMIT EECS 6.837, Teller and Durand10Ray Casting Outline• For every pixel construct a ray from the eye • For every object in the scene– Find closest intersection with the ray – Compute normal at point of intersection• Compute color for pixel (e.g. Phong)MIT EECS 6.837, Teller and Durand11Ray CastingObject Cast ( Point R, Ray D ) {find minimum t>0 such that R + t D hits objectif ( object hit )return objectelse return background object}MIT EECS 6.837, Teller and Durand12Ray CastingFrameBuffer Render ( frustum, viewport ) {For each raster yFor each pixel xD = ray from eye through pixel x, yobj = Cast ( eye, D );FrameBuffer[x,y] = obj->color}MIT EECS 6.837, Teller and Durand13Ray Casting for Visibility• Advantages?– Smooth variation of normal, silhouettes– Generality: can render anything with which a ray can be intersected !– Compactness of representation– Atomic operationMIT EECS 6.837, Teller and Durand14Ray Casting for Visibility• Disadvantages?– Time complexity (N objects, R pixels)–?– Wasted work at “background" pixels– Why aren't ray casters usually found in hardware?MIT EECS 6.837, Teller and Durand15Ray Casting vs. Scan conversion• Ray casting:– More and more used in production • Final Fantasy, The Cell, Fight Club, The City of Lost Children– Some hardware is appearing– Volume Rendering• Scan conversion– Graphics card– Pixar Renderman• Toy Story, Monsters, Jurassic Park, Most of Final FantasyMIT EECS 6.837, Teller and Durand16Durer’s Ray casting machine• Albrecht Durer, 16thcenturyMIT EECS 6.837, Teller and Durand17Durer’s Ray casting machine• Albrecht Durer, 16thcenturyMIT EECS 6.837, Teller and Durand18Durer’s Ray casting machine• Albrecht Durer, 16thcenturyMIT EECS 6.837, Teller and Durand19Questions?• Image by Henrik Wann Jensen using Ray Casting (and some other advanced techniques)MIT EECS 6.837, Teller and Durand20Overview• Ray casting• Transformations• Ray-Primitive intersection• Advanced ray casting• Ray TracingMIT EECS 6.837, Teller and Durand21First Step - From Pixels to RaysMIT EECS 6.837, Teller and Durand22Ray-Scene Intersection• Given a ray, & a scene of transformed primitives– Determine:• Closest ray-primitive intersection P, if any• Primitive's surface normal N at point P•Compute t for each intersection, and retain tminMIT EECS 6.837, Teller and Durand23Ray-Primitive Intersection• First concentrate on individual primitives• Ray is typically generated in world space• Primitives defined in object space, then transformed• What are our options?MMIT EECS 6.837, Teller and Durand24Opt 1: Intersection in World Space• Transform primitive into world space– Reexpress it there, then perform intersectionMMIT EECS 6.837, Teller and Durand25Opt 1: Intersection in World Space• Option 1: transform primitive into world space– Reexpress it there, then perform intersection• Polygon: vertices p as Mp, plane H as HM-1– Polyhedra: collections of polygonsMRDMIT EECS 6.837, Teller and Durand26Opt 1: Intersection in World Space• Option 1: transform primitive into world space• Polygon: vertices as Mp, plane as HM-1• Quadrics Q: transform as MQM-1– But: quadric class is not invariant !• Torii, spline surfaces, other primitives: harder.MMIT EECS 6.837, Teller and Durand27Opt 1: Intersection in World Space• Option 1: transform primitive into world space• Requires one transformation rule for each class of object• Any better idea?MMIT EECS 6.837, Teller and Durand28Opt 2: Intersection in Object Space• Transform ray into object space!– Intersections straightforward, even trivial there• How do we transform the ray's origin and direction?M-1MIT EECS 6.837, Teller and Durand29Opt 2: Intersection in Object Space• Transform ray origin into object space–R’ = M-1R• How do we transform the ray's direction?M-1RDWorldObjectMIT EECS 6.837, Teller and Durand30Ray Transformation• How do we transform the ray's direction?– NOT as D’ = M-1DM-1RDWorldObjectMIT EECS 6.837, Teller and Durand31Direction vector transformation• “Endpoints" of ray have equal translations• Equivalently: ray is a pure direction• So: transform both ends, subtract resultsM-1RDWorldObjectMIT EECS 6.837, Teller and Durand32Direction vector transformation• Equivalent to ignoring translation part of M• Instead, use• Again: can treat direction (a; b; c) as homogeneous (a; b; c; 0)• Inventor supplies this


View Full Document

MIT 6 837 - Ray Tracing

Documents in this Course
Shadows

Shadows

64 pages

Animation

Animation

37 pages

Radiosity

Radiosity

25 pages

Color

Color

86 pages

InterArch

InterArch

14 pages

Color

Color

15 pages

Animation

Animation

61 pages

Luxo Jr

Luxo Jr

14 pages

Animation

Animation

52 pages

Radiosity

Radiosity

37 pages

Load more
Download Ray Tracing
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Ray Tracing and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Ray Tracing 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?