SlideShare une entreprise Scribd logo
1  sur  36
Embarrassingly
Parallel Computation
for Visibility
Jasin Bushnaief
Umbra Software
Who are we?
• The only occlusion culling middleware
  company in the world
• Founded in 2006
• Based in Helsinki
• 12 people
• Customers: Bungie (Halo), Guerrilla (Killzone),
  Remedy (Alan Wake), Bioware (Mass Effect),
  CD Projekt (Witcher), ArenaNet (Guild Wars)
  and many more
We’re going to talk about
• The past
  – Brief introduction to occlusion culling
  – Traditional methods of visibility computation
• The present
  – Umbra’s visibility computation algorithm
  – How it can be distributed
• The future
  – Challenges of modern games and engines
The Past:

SO, WHAT’S OCCLUSION CULLING
ANYWAY?
Graphics in games
• Game development process:
  – Artists create content
  – Engine runtime renders it
• Rendering
  – Content consists of objects
  – Which consist of triangles
  – Which get rendered by the GPU
• Our business: rendering optimization
Occlusion culling explained
• ”Culling is the process of removing breeding
  animals from a group based on specific criteria.”
  (Wikipedia)
• Hidden surface removal: ”Which surfaces do not
  contribute to the final rendered image on the
  screen?”
• Some popular HSR methods:
  – Frustum culling
  – Backface culling
  – Occlusion culling
Occlusion culling explained
• Occlusion culling: ”Which surfaces are blocked
  (occluded) by other surfaces?”
• Depth buffering is one way to do OC
  – Very accurate (i.e. pixel level)
  – Ubiquitous on hardware, easy problem to solve
  – Occurs very late in the pipeline
Occlusion culling explained
• Higher-level methods complement depth-
  buffering nicely
• These cull entire objects, groups of objects or
  entire sections of the scene
  – Not easy!
• The earlier, the better
Occlusion culling




Only the objects visible to
the camera are rendered
”Traditional” way to do OC
• Preprocess:
  – Divide scene into cells
  – Compute visibility between cells
     • Results in a visibility matrix (PVS)
• Runtime:
  – Locate the camera
  – Do a lookup into the PVS matrix
Simple example
Split scene into cells

 A            B


 C            D
Compute visibility (sampling)

     A            B
                             A B   C   D
                         A 1   1   1   0
                         B
                         C
                         D

     C            D
Compute visibility

A           B
                         A B     C   D
                     A 1     1   1   0
                     B   1   1   0   1
                     C
                     D

C           D
Compute visibility

A           B
                         A B     C   D
                     A 1     1   1   0
                     B   1   1   0   1
                     C   1   0   1   1
                     D

C           D
Compute visibility

A           B
                         A B     C   D
                     A 1     1   1   0
                     B   1   1   0   1
                     C   1   0   1   1
                     D 0     1   1   1

C           D
Runtime PVS culling

A           B
                          A B     C   D
                      A 1     1   1   0
                      B   1   1   0   1
                      C   1   0   1   1
                      D 0     1   1   1

C           D
Problem?
• Solving visibility between cells is very difficult
   – E.g. Solving analytically is actually O(n4)
• Global operation by nature
• Doesn’t play well with dynamic scenes
   – Worst case: a change in one cell requires
     recomputation of the entire matrix
The Present

UMBRA DOES IT BETTER
Welcome to the 2010s
• Modern game worlds are huge
• So it’d be cool if you didn’t need the entire
  scene in memory, ever
• It’d be even cooler if the heavy lifting could be
  distributed. Or sent to the Cloud™
• Buildings collapse. Things change.
The Umbra approach
• Don’t actually compute visibility for the entire
  scene
• Instead, process geometry to create a
  datastructure to solve visibility in the runtime
• Portal culling in the runtime
Data generation
• Data = portal graph
• Generate local graphs individually reasonably-
  sized geometry chunks (tiles), in parallel
• Combine the results into a global portal graph
  that can be quickly traversed
• Solve visibility quickly in the runtime using this
  graph
Will this work?
• Portal generation
  – Is very hard, but possible to do automatically
  – Only local geometry needed
  →Pretty much an embarrassingly parallel problem
• Runtime
  – Not as simple as a PVS lookup, but still quite fast
Simple example revisited
Split geometry into tiles
Dispatch tiles to worker nodes


 Tile 0   Tile 1   Tile 2   Tile 3
Generate portals


Tile 0     Tile 1   Tile 2   Tile 3
Combine portal graph
Runtime query: traverse portals
What did we do here?
 • Essentially a map-reduce
        – Split scene into distributable tiles
        – Generate local portal graph for each tile
        – Combine results, link global portal graph
                                                                   Runtime
Scene                Tile 0   Portals 0            Global portal             Visible
                                                   graph                     objects


                                          Reduce
                     Tile 1   Portals 1




                                                                   Query
               Map




                        ...      ...

                     Tile n   Portals n
The Future

THE NEXT GENERATION
Turns out...
• Even the initial ”map” is too much for large
  game worlds
• A global graph of a vast world is too expensive
  in the runtime
• You need to support multiple versions of some
  chunks for dynamic content
  – Quite a combinatorial problem
→ Next-gen games require an even better
solution!
So we did something like this
                               Runtime
          Tile 0   Portals 0             Graph A           Visible
                                                           objects




                               Combine




                                                   Query
          Tile 1   Portals 1

          Tile 2   Portals 2

          Tile 3   Portals 3             Graph B           Visible



                               Combine
                                                           objects




                                                   Query
...          ...      ...

          Tile n   Portals n
Got rid of ”map”
                               Runtime
      Tile 0       Portals 0             Graph A           Visible
                                                           objects




                               Combine




                                                   Query
      Tile 1       Portals 1

      Tile 2       Portals 2

      Tile 3       Portals 3             Graph B           Visible



                               Combine
                                                           objects




                                                   Query
...      ...          ...

      Tile n       Portals n
Split up ”reduce”, moved to runtime
                           Runtime
      Tile 0   Portals 0             Graph A           Visible
                                                       objects




                           Combine




                                               Query
      Tile 1   Portals 1

      Tile 2   Portals 2

      Tile 3   Portals 3             Graph B           Visible



                           Combine
                                                       objects




                                               Query
...      ...      ...

      Tile n   Portals n
Questions?




jasin@umbrasoftware.com

Contenu connexe

Similaire à Embarrassingly Parallel Computation for Occlusion Culling

Graphicsand animations devoxx2010 (1)
Graphicsand animations devoxx2010 (1)Graphicsand animations devoxx2010 (1)
Graphicsand animations devoxx2010 (1)Marakana Inc.
 
Graphs in the Database: Rdbms In The Social Networks Age
Graphs in the Database: Rdbms In The Social Networks AgeGraphs in the Database: Rdbms In The Social Networks Age
Graphs in the Database: Rdbms In The Social Networks AgeLorenzo Alberton
 
Benoit fouletier guillaume martin unity day- modern 2 d techniques-gce2014
Benoit fouletier guillaume martin   unity day- modern 2 d techniques-gce2014Benoit fouletier guillaume martin   unity day- modern 2 d techniques-gce2014
Benoit fouletier guillaume martin unity day- modern 2 d techniques-gce2014Mary Chan
 
Designing an Objective-C Framework about 3D
Designing an Objective-C Framework about 3DDesigning an Objective-C Framework about 3D
Designing an Objective-C Framework about 3Drsebbe
 
[HTML5 BUG] 2,5D RTS Game in HTML5 by Dawid Lijewski
[HTML5 BUG] 2,5D RTS Game in HTML5 by Dawid Lijewski[HTML5 BUG] 2,5D RTS Game in HTML5 by Dawid Lijewski
[HTML5 BUG] 2,5D RTS Game in HTML5 by Dawid LijewskiBeMyApp
 
CS 354 Procedural Methods
CS 354 Procedural MethodsCS 354 Procedural Methods
CS 354 Procedural MethodsMark Kilgard
 
Workflows for developing next gen 3D browser games
Workflows for developing next gen 3D browser gamesWorkflows for developing next gen 3D browser games
Workflows for developing next gen 3D browser gamesMichael Plank
 
CG simple openGL point & line-course 2
CG simple openGL point & line-course 2CG simple openGL point & line-course 2
CG simple openGL point & line-course 2fungfung Chen
 
Pitfalls of object_oriented_programming_gcap_09
Pitfalls of object_oriented_programming_gcap_09Pitfalls of object_oriented_programming_gcap_09
Pitfalls of object_oriented_programming_gcap_09Royce Lu
 
Automatically Defined Functions for Learning Classifier Systems
Automatically Defined Functions for Learning Classifier SystemsAutomatically Defined Functions for Learning Classifier Systems
Automatically Defined Functions for Learning Classifier SystemsDaniele Loiacono
 
Lecture 2: Data-Intensive Computing for Text Analysis (Fall 2011)
Lecture 2: Data-Intensive Computing for Text Analysis (Fall 2011)Lecture 2: Data-Intensive Computing for Text Analysis (Fall 2011)
Lecture 2: Data-Intensive Computing for Text Analysis (Fall 2011)Matthew Lease
 
CG OpenGL surface detection+illumination+rendering models-course 9
CG OpenGL surface detection+illumination+rendering models-course 9CG OpenGL surface detection+illumination+rendering models-course 9
CG OpenGL surface detection+illumination+rendering models-course 9fungfung Chen
 
WOOster: A Map-Reduce based Platform for Graph Mining
WOOster: A Map-Reduce based Platform for Graph MiningWOOster: A Map-Reduce based Platform for Graph Mining
WOOster: A Map-Reduce based Platform for Graph Miningaravindan_raghu
 
09_Practical Multicore programming
09_Practical Multicore programming09_Practical Multicore programming
09_Practical Multicore programmingnoerror
 
TomTom for Business Process Managment (TomTom4BPM)
TomTom for Business Process Managment (TomTom4BPM)TomTom for Business Process Managment (TomTom4BPM)
TomTom for Business Process Managment (TomTom4BPM)Wil van der Aalst
 
[Harvard CS264] 03 - Introduction to GPU Computing, CUDA Basics
[Harvard CS264] 03 - Introduction to GPU Computing, CUDA Basics[Harvard CS264] 03 - Introduction to GPU Computing, CUDA Basics
[Harvard CS264] 03 - Introduction to GPU Computing, CUDA Basicsnpinto
 

Similaire à Embarrassingly Parallel Computation for Occlusion Culling (19)

Graphicsand animations devoxx2010 (1)
Graphicsand animations devoxx2010 (1)Graphicsand animations devoxx2010 (1)
Graphicsand animations devoxx2010 (1)
 
Graphs in the Database: Rdbms In The Social Networks Age
Graphs in the Database: Rdbms In The Social Networks AgeGraphs in the Database: Rdbms In The Social Networks Age
Graphs in the Database: Rdbms In The Social Networks Age
 
Benoit fouletier guillaume martin unity day- modern 2 d techniques-gce2014
Benoit fouletier guillaume martin   unity day- modern 2 d techniques-gce2014Benoit fouletier guillaume martin   unity day- modern 2 d techniques-gce2014
Benoit fouletier guillaume martin unity day- modern 2 d techniques-gce2014
 
December 4, Project
December 4, ProjectDecember 4, Project
December 4, Project
 
05 cubetech
05 cubetech05 cubetech
05 cubetech
 
Designing an Objective-C Framework about 3D
Designing an Objective-C Framework about 3DDesigning an Objective-C Framework about 3D
Designing an Objective-C Framework about 3D
 
[HTML5 BUG] 2,5D RTS Game in HTML5 by Dawid Lijewski
[HTML5 BUG] 2,5D RTS Game in HTML5 by Dawid Lijewski[HTML5 BUG] 2,5D RTS Game in HTML5 by Dawid Lijewski
[HTML5 BUG] 2,5D RTS Game in HTML5 by Dawid Lijewski
 
Bigdata roundtable-storm
Bigdata roundtable-stormBigdata roundtable-storm
Bigdata roundtable-storm
 
CS 354 Procedural Methods
CS 354 Procedural MethodsCS 354 Procedural Methods
CS 354 Procedural Methods
 
Workflows for developing next gen 3D browser games
Workflows for developing next gen 3D browser gamesWorkflows for developing next gen 3D browser games
Workflows for developing next gen 3D browser games
 
CG simple openGL point & line-course 2
CG simple openGL point & line-course 2CG simple openGL point & line-course 2
CG simple openGL point & line-course 2
 
Pitfalls of object_oriented_programming_gcap_09
Pitfalls of object_oriented_programming_gcap_09Pitfalls of object_oriented_programming_gcap_09
Pitfalls of object_oriented_programming_gcap_09
 
Automatically Defined Functions for Learning Classifier Systems
Automatically Defined Functions for Learning Classifier SystemsAutomatically Defined Functions for Learning Classifier Systems
Automatically Defined Functions for Learning Classifier Systems
 
Lecture 2: Data-Intensive Computing for Text Analysis (Fall 2011)
Lecture 2: Data-Intensive Computing for Text Analysis (Fall 2011)Lecture 2: Data-Intensive Computing for Text Analysis (Fall 2011)
Lecture 2: Data-Intensive Computing for Text Analysis (Fall 2011)
 
CG OpenGL surface detection+illumination+rendering models-course 9
CG OpenGL surface detection+illumination+rendering models-course 9CG OpenGL surface detection+illumination+rendering models-course 9
CG OpenGL surface detection+illumination+rendering models-course 9
 
WOOster: A Map-Reduce based Platform for Graph Mining
WOOster: A Map-Reduce based Platform for Graph MiningWOOster: A Map-Reduce based Platform for Graph Mining
WOOster: A Map-Reduce based Platform for Graph Mining
 
09_Practical Multicore programming
09_Practical Multicore programming09_Practical Multicore programming
09_Practical Multicore programming
 
TomTom for Business Process Managment (TomTom4BPM)
TomTom for Business Process Managment (TomTom4BPM)TomTom for Business Process Managment (TomTom4BPM)
TomTom for Business Process Managment (TomTom4BPM)
 
[Harvard CS264] 03 - Introduction to GPU Computing, CUDA Basics
[Harvard CS264] 03 - Introduction to GPU Computing, CUDA Basics[Harvard CS264] 03 - Introduction to GPU Computing, CUDA Basics
[Harvard CS264] 03 - Introduction to GPU Computing, CUDA Basics
 

Dernier

How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024BookNet Canada
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Neo4j
 
Unlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power SystemsUnlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power SystemsPrecisely
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024BookNet Canada
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDGMarianaLemus7
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 

Dernier (20)

How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
Unlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power SystemsUnlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power Systems
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDG
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 

Embarrassingly Parallel Computation for Occlusion Culling

  • 2. Who are we? • The only occlusion culling middleware company in the world • Founded in 2006 • Based in Helsinki • 12 people • Customers: Bungie (Halo), Guerrilla (Killzone), Remedy (Alan Wake), Bioware (Mass Effect), CD Projekt (Witcher), ArenaNet (Guild Wars) and many more
  • 3. We’re going to talk about • The past – Brief introduction to occlusion culling – Traditional methods of visibility computation • The present – Umbra’s visibility computation algorithm – How it can be distributed • The future – Challenges of modern games and engines
  • 4. The Past: SO, WHAT’S OCCLUSION CULLING ANYWAY?
  • 5. Graphics in games • Game development process: – Artists create content – Engine runtime renders it • Rendering – Content consists of objects – Which consist of triangles – Which get rendered by the GPU • Our business: rendering optimization
  • 6. Occlusion culling explained • ”Culling is the process of removing breeding animals from a group based on specific criteria.” (Wikipedia) • Hidden surface removal: ”Which surfaces do not contribute to the final rendered image on the screen?” • Some popular HSR methods: – Frustum culling – Backface culling – Occlusion culling
  • 7. Occlusion culling explained • Occlusion culling: ”Which surfaces are blocked (occluded) by other surfaces?” • Depth buffering is one way to do OC – Very accurate (i.e. pixel level) – Ubiquitous on hardware, easy problem to solve – Occurs very late in the pipeline
  • 8. Occlusion culling explained • Higher-level methods complement depth- buffering nicely • These cull entire objects, groups of objects or entire sections of the scene – Not easy! • The earlier, the better
  • 9. Occlusion culling Only the objects visible to the camera are rendered
  • 10. ”Traditional” way to do OC • Preprocess: – Divide scene into cells – Compute visibility between cells • Results in a visibility matrix (PVS) • Runtime: – Locate the camera – Do a lookup into the PVS matrix
  • 12. Split scene into cells A B C D
  • 13. Compute visibility (sampling) A B A B C D A 1 1 1 0 B C D C D
  • 14. Compute visibility A B A B C D A 1 1 1 0 B 1 1 0 1 C D C D
  • 15. Compute visibility A B A B C D A 1 1 1 0 B 1 1 0 1 C 1 0 1 1 D C D
  • 16. Compute visibility A B A B C D A 1 1 1 0 B 1 1 0 1 C 1 0 1 1 D 0 1 1 1 C D
  • 17. Runtime PVS culling A B A B C D A 1 1 1 0 B 1 1 0 1 C 1 0 1 1 D 0 1 1 1 C D
  • 18. Problem? • Solving visibility between cells is very difficult – E.g. Solving analytically is actually O(n4) • Global operation by nature • Doesn’t play well with dynamic scenes – Worst case: a change in one cell requires recomputation of the entire matrix
  • 20. Welcome to the 2010s • Modern game worlds are huge • So it’d be cool if you didn’t need the entire scene in memory, ever • It’d be even cooler if the heavy lifting could be distributed. Or sent to the Cloud™ • Buildings collapse. Things change.
  • 21. The Umbra approach • Don’t actually compute visibility for the entire scene • Instead, process geometry to create a datastructure to solve visibility in the runtime • Portal culling in the runtime
  • 22. Data generation • Data = portal graph • Generate local graphs individually reasonably- sized geometry chunks (tiles), in parallel • Combine the results into a global portal graph that can be quickly traversed • Solve visibility quickly in the runtime using this graph
  • 23. Will this work? • Portal generation – Is very hard, but possible to do automatically – Only local geometry needed →Pretty much an embarrassingly parallel problem • Runtime – Not as simple as a PVS lookup, but still quite fast
  • 26. Dispatch tiles to worker nodes Tile 0 Tile 1 Tile 2 Tile 3
  • 27. Generate portals Tile 0 Tile 1 Tile 2 Tile 3
  • 30. What did we do here? • Essentially a map-reduce – Split scene into distributable tiles – Generate local portal graph for each tile – Combine results, link global portal graph Runtime Scene Tile 0 Portals 0 Global portal Visible graph objects Reduce Tile 1 Portals 1 Query Map ... ... Tile n Portals n
  • 31. The Future THE NEXT GENERATION
  • 32. Turns out... • Even the initial ”map” is too much for large game worlds • A global graph of a vast world is too expensive in the runtime • You need to support multiple versions of some chunks for dynamic content – Quite a combinatorial problem → Next-gen games require an even better solution!
  • 33. So we did something like this Runtime Tile 0 Portals 0 Graph A Visible objects Combine Query Tile 1 Portals 1 Tile 2 Portals 2 Tile 3 Portals 3 Graph B Visible Combine objects Query ... ... ... Tile n Portals n
  • 34. Got rid of ”map” Runtime Tile 0 Portals 0 Graph A Visible objects Combine Query Tile 1 Portals 1 Tile 2 Portals 2 Tile 3 Portals 3 Graph B Visible Combine objects Query ... ... ... Tile n Portals n
  • 35. Split up ”reduce”, moved to runtime Runtime Tile 0 Portals 0 Graph A Visible objects Combine Query Tile 1 Portals 1 Tile 2 Portals 2 Tile 3 Portals 3 Graph B Visible Combine objects Query ... ... ... Tile n Portals n