ray tracing for ray tracing for
play

Ray tracing for Ray tracing for Cars challenges Cars challenges - PDF document

Per ChristensenPer Christensen Ray tracing for Ray tracing for Cars challenges Cars challenges the movie Cars the movie Cars Animation: cars that move, talk, think Animation: cars that move, talk, think


  1. Per ChristensenPer Christensen Ray tracing for Ray tracing for Cars challenges Cars challenges the movie ‘Cars’ the movie ‘Cars’ • Animation: cars that move, talk, “think” Animation: cars that move, talk, “think” • • Rendering: • Rendering: – geometric complexity – geometric complexity – ray tracing: reflections, shadows, ambient – ray tracing: reflections, shadows, ambient occlusion occlusion Per Christensen Per Christensen Pixar Animation Studios Pixar Animation Studios Ayia Ayia Napa Seminar, June 2006 Napa Seminar, June 2006 Overview Overview Why ray tracing for Cars? Why ray tracing for Cars? • Why ray tracing? Why ray tracing? • All previous All previous Pixar Pixar movies were rendered movies were rendered • • with scanline scanline rendering (shadow maps, rendering (shadow maps, with • How to deal with overwhelming • How to deal with overwhelming reflection maps, …) reflection maps, …) complexity? complexity? • But cars are very shiny + reflective! But cars are very shiny + reflective! • • • Examples Examples • Shadows; ambient occlusion • Shadows; ambient occlusion • We were adding ray tracing to • We were adding ray tracing to RenderMan RenderMan anyway anyway Why ray tracing? Why ray tracing? Why ray tracing? Why ray tracing? Environment map Environment map Ray Ray- -traced reflections traced reflections Ray Ray- -traced shadows (shadow maps hard) traced shadows (shadow maps hard) An irradiance atlas ...Ray tracing for Cars 1

  2. Per ChristensenPer Christensen Why ray tracing? Ray tracing effects: summary Why ray tracing? Ray tracing effects: summary sharp shadow self inter- reflection soft shadow Ambient occlusion Ambient occlusion mirror reflection Ray tracing is easy – Ray tracing is easy – or is it? or is it? Typical scene at Pixar Typical scene at Pixar • Yes Yes – – but only if the scene fits in memory! but only if the scene fits in memory! • 100s of lights 100s of lights • • • • Further complications: Further complications: • 1,000s of textures • 1,000s of textures – – too many to fit in too many to fit in mem mem! ! – Displacement – Displacement shaders shaders • 10,000s of objects • 10,000s of objects – Motion blur – Motion blur • 100,000,000s of polygons • 100,000,000s of polygons – – too many to fit! too many to fit! – – … … • Shaders Shaders with 10,000s lines of code with 10,000s lines of code • Rendering requirements Rendering requirements Scanline Scanline rendering (Reyes) rendering (Reyes) • Render at hi Render at hi- -res (~ 2000 pixels) res (~ 2000 pixels) • Advantages: Advantages: • • – Fast – Fast • Motion blur Motion blur • – One image tile at a time: only needs small – One image tile at a time: only needs small fraction of objects+ textures fraction of objects+ textures – Can deal with very complex scenes – Can deal with very complex scenes • Depth of field • Depth of field • Limitations: Limitations: • – Shadow maps (limited resolution) – Shadow maps (limited resolution) • No spatial or temporal aliasing (staircase No spatial or temporal aliasing (staircase • – Reflection maps (no Reflection maps (no interreflections interreflections) ) – effects, “crawlies”, popping, …) effects, “crawlies”, popping, …) An irradiance atlas ...Ray tracing for Cars 2

  3. Per ChristensenPer Christensen Ray tracing Goal: best of both Ray tracing Goal: best of both • Advantages: Advantages: • • Ray tracing • Ray tracing – – Interreflections Interreflections • Very complex scenes (as • Very complex scenes (as scanline scanline) ) – Fine shadow details Fine shadow details – • So: augment So: augment RenderMan’s RenderMan’s Reyes Reyes scanline scanline • – Ambient occlusion – Ambient occlusion with ray tracing with ray tracing • • Disadvantage: rays fly all over the scene Disadvantage: rays fly all over the scene – Needs all objects+ textures all the time – Needs all objects+ textures all the time – Can – Can not not deal with very complex scenes deal with very complex scenes Main question Main question Ray differentials to the rescue Ray differentials to the rescue • Some rays fly all over Some rays fly all over • Keep track of differences between Keep track of differences between • • “neighbor” rays “neighbor” rays • • Some rays require high geometric / Some rays require high geometric / texture precision texture precision • Trace rays; each ray represents a beam • Trace rays; each ray represents a beam [ Igehy Igehy 1999] 1999] [ • • But But not all rays fly all over and require not all rays fly all over and require high precision! high precision! • • Which rays require which precision? Which rays require which precision? Ray differentials and ray beam Ray differentials and ray beam Ray differentials: use Ray differentials: use Ray differentials tell us: Ray differentials tell us: ray • Required tessellation rate of geometry Required tessellation rate of geometry • ray beam – Quad sizes ~ ray beam cross – Quad sizes ~ ray beam cross- -section section neighbor rays • Required texture resolution Required texture resolution • – Pixel sizes ~ ray beam projected onto surface – Pixel sizes ~ ray beam projected onto surface • “ • “Narrow ray”: ray beam cross Narrow ray”: ray beam cross- -section is small section is small • “Wide ray”: ray beam cross • “Wide ray”: ray beam cross- -section is large section is large An irradiance atlas ...Ray tracing for Cars 3

  4. Per ChristensenPer Christensen Multi- -resolution geometry cache resolution geometry cache Multi- -resolution geometry cache resolution geometry cache Multi Multi • Store tessellation in coarse, medium, • Store tessellation in coarse, medium, • • Split objects into patches (as usual) Split objects into patches (as usual) or fine sub- or fine sub -cache cache • Tessellate each patch on demand • Tessellate each patch on demand • • Same size (e.g. 10MB) but different Same size (e.g. 10MB) but different • Use ray width to determine which Use ray width to determine which • capacity capacity tessellation to use: tessellation to use: • Coherent lookups in medium + fine Coherent lookups in medium + fine • sub- -cache cache sub • Result: can render scenes • Result: can render scenes 100 x larger 100 x larger than cache size ! than cache size ! 1 quad 4x4 quads 16x16 quads 1 quad 4x4 quads 16x16 quads Example: parking lot Example: parking lot Parking lot: cache stats Parking lot: cache stats • 1 billion geometry cache lookups 1 billion geometry cache lookups • • No cache: run time > 4 days • No cache: run time > 4 days • Single • Single- -resolution cache: resolution cache: – hit rate 97.7% – hit rate 97.7% – run time: 11 hours – run time: 11 hours • Multi Multi- -resolution cache: resolution cache: • – hit rate 99.9% – hit rate 99.9% 15 cars; 240M quads; 80M rays – run time: 6 hours run time: 6 hours 15 cars; 240M quads; 80M rays – Example: 94 dragons Example: 94 dragons 94 dragons: cache stats 94 dragons: cache stats displacements textures • 18 million geometry cache lookups 18 million geometry cache lookups • • 3MB multi 3MB multi- -res. cache performs well res. cache performs well – – less less • than 1/200 of the fully tessellated scene than 1/200 of the fully tessellated scene • Single • Single- -res. vs. multi res. vs. multi- -res. geometry cache: res. geometry cache: – 1MB multi – 1MB multi- -res. cache beats 100MB single res. cache beats 100MB single- -res. res. cache (# recomputed vertices) cache (# recomputed vertices) sharp shadows mirror reflection An irradiance atlas ...Ray tracing for Cars 4

  5. Per ChristensenPer Christensen Final car images … Final car images … Final car images … Final car images … Final car images … Final car images … Final car images … Final car images … Movie time Movie time More information … More information … • Book: Book: Advanced Advanced RenderMan RenderMan • • “Ray differentials and “Ray differentials and multiresolution multiresolution • geometry caching for distribution ray tracing geometry caching for distribution ray tracing in complex scenes”, Eurographics Eurographics 2003 2003 in complex scenes”, An irradiance atlas ...Ray tracing for Cars 5

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend