Occluder Simplification using Planar Sections

Similar documents
DiFi: Distance Fields - Fast Computation Using Graphics Hardware

Wed, October 12, 2011

Shadows. COMP 575/770 Spring 2013

Some Thoughts on Visibility

Visibility. Tom Funkhouser COS 526, Fall Slides mostly by Frédo Durand

Motivation. Culling Don t draw what you can t see! What can t we see? Low-level Culling

Frédo Durand, George Drettakis, Joëlle Thollot and Claude Puech

Real-Time Rendering (Echtzeitgraphik) Dr. Michael Wimmer

S U N G - E U I YO O N, K A I S T R E N D E R I N G F R E E LY A VA I L A B L E O N T H E I N T E R N E T

Physically-Based Laser Simulation

Computer Graphics Ray Casting. Matthias Teschner

Accelerating Geometric Queries. Computer Graphics CMU /15-662, Fall 2016

Shadows for Many Lights sounds like it might mean something, but In fact it can mean very different things, that require very different solutions.

CS 563 Advanced Topics in Computer Graphics QSplat. by Matt Maziarz

Assignment 6: Ray Tracing

Comparison of hierarchies for occlusion culling based on occlusion queries

Universiteit Leiden Computer Science

The Traditional Graphics Pipeline

Mesh Decimation. Mark Pauly

The Traditional Graphics Pipeline

Let s start with occluding contours (or interior and exterior silhouettes), and look at image-space algorithms. A very simple technique is to render

Rendering. Converting a 3D scene to a 2D image. Camera. Light. Rendering. View Plane

A Different Approach for Continuous Physics. Vincent ROBERT Physics Programmer at Ubisoft

CSE 167: Introduction to Computer Graphics Lecture #11: Visibility Culling

Spatial Data Structures and Speed-Up Techniques. Tomas Akenine-Möller Department of Computer Engineering Chalmers University of Technology

Scene Management. Video Game Technologies 11498: MSc in Computer Science and Engineering 11156: MSc in Game Design and Development

Topics and things to know about them:

Simplified Mesh Generation from Renders. Thorvald Natvig

Culling. Computer Graphics CSE 167 Lecture 12

improving raytracing speed

CSE 167: Introduction to Computer Graphics Lecture #10: View Frustum Culling

Specialized Acceleration Structures for Ray-Tracing. Warren Hunt

Level of Details in Computer Rendering

Computer Graphics. Si Lu. Fall uter_graphics.htm 11/22/2017

CPSC GLOBAL ILLUMINATION

CHAPTER 1 Graphics Systems and Models 3

Mesh Repairing and Simplification. Gianpaolo Palma

The Traditional Graphics Pipeline

L1 - Introduction. Contents. Introduction of CAD/CAM system Components of CAD/CAM systems Basic concepts of graphics programming

Speeding up your game

Ray Tracing. Computer Graphics CMU /15-662, Fall 2016

Who has worked on a voxel engine before? Who wants to? My goal is to give the talk I wish I would have had before I started on our procedural engine.

CS 4620 Midterm, March 21, 2017

Scalable many-light methods

Computer Graphics (CS 543) Lecture 13b Ray Tracing (Part 1) Prof Emmanuel Agu. Computer Science Dept. Worcester Polytechnic Institute (WPI)

Spatial Data Structures

Rasterization Overview

VISIBILITY & CULLING. Don t draw what you can t see. Thomas Larsson, Afshin Ameri DVA338, Spring 2018, MDH

Computer Graphics Shadow Algorithms

Point based Rendering

CS488. Visible-Surface Determination. Luc RENAMBOT

Real-Time Shadows. MIT EECS 6.837, Durand and Cutler

3D Modeling: Surfaces

CGAL. Mesh Simplification. (Slides from Tom Funkhouser, Adam Finkelstein)

Surface Simplification Using Quadric Error Metrics

Spatial Data Structures

Pipeline Operations. CS 4620 Lecture 10

Triangle Rasterization

CPSC / Sonny Chan - University of Calgary. Collision Detection II

SUMMARY. CS380: Introduction to Computer Graphics Ray tracing Chapter 20. Min H. Kim KAIST School of Computing 18/05/29. Modeling

Acceleration Data Structures

Goal. Interactive Walkthroughs using Multiple GPUs. Boeing 777. DoubleEagle Tanker Model

Real-Time Shadows. Last Time? Schedule. Questions? Today. Why are Shadows Important?

4: Polygons and pixels

Real-Time Shadows. Last Time? Today. Why are Shadows Important? Shadows as a Depth Cue. For Intuition about Scene Lighting

Topic #1: Rasterization (Scan Conversion)

CSE 167: Introduction to Computer Graphics Lecture #9: Visibility. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2018

Pipeline Operations. CS 4620 Lecture 14

Conservative occlusion culling for urban visualization using a slice-wise data structure

CS 498 VR. Lecture 18-4/4/18. go.illinois.edu/vrlect18

Visible Surface Detection. (Chapt. 15 in FVD, Chapt. 13 in Hearn & Baker)

Point Cloud Filtering using Ray Casting by Eric Jensen 2012 The Basic Methodology

MIT EECS 6.837, Teller and Durand 1

FRUSTUM-TRACED RASTER SHADOWS: REVISITING IRREGULAR Z-BUFFERS

CS 563 Advanced Topics in Computer Graphics Culling and Acceleration Techniques Part 1 by Mark Vessella

Volume Shadows Tutorial Nuclear / the Lab

Chapter 11 Global Illumination. Part 1 Ray Tracing. Reading: Angel s Interactive Computer Graphics (6 th ed.) Sections 11.1, 11.2, 11.

Dynamic Ambient Occlusion and Indirect Lighting. Michael Bunnell NVIDIA Corporation

Texture Mapping II. Light maps Environment Maps Projective Textures Bump Maps Displacement Maps Solid Textures Mipmaps Shadows 1. 7.

Graphics 2009/2010, period 1. Lecture 8: ray tracing

Ray Tracing Acceleration Data Structures

Ray Tracing. Foley & Van Dam, Chapters 15 and 16

Math 3C Section 9.1 & 9.2

Ray Tracing Foley & Van Dam, Chapters 15 and 16

Pipeline Operations. CS 4620 Lecture Steve Marschner. Cornell CS4620 Spring 2018 Lecture 11

Visibility and Occlusion Culling

CMSC427 Advanced shading getting global illumination by local methods. Credit: slides Prof. Zwicker

Last Time: Acceleration Data Structures for Ray Tracing. Schedule. Today. Shadows & Light Sources. Shadows

Introduction to Visualization and Computer Graphics

Spatial Data Structures

Homework #2 and #3 Due Friday, October 12 th and Friday, October 19 th

Visibility Preprocessing with Occluder Fusion for Urban Walkthroughs

Deferred Rendering Due: Wednesday November 15 at 10pm

All the Polygons You Can Eat. Doug Rogers Developer Relations

Graphics and Interaction Rendering pipeline & object modelling

Mesh Decimation Using VTK

Clipping & Culling. Lecture 11 Spring Trivial Rejection Outcode Clipping Plane-at-a-time Clipping Backface Culling

Soft shadows. Steve Marschner Cornell University CS 569 Spring 2008, 21 February

Here s the general problem we want to solve efficiently: Given a light and a set of pixels in view space, resolve occlusion between each pixel and

Z-Buffer hold pixel's distance from camera. Z buffer

Transcription:

Occluder Simplification using Planar Sections Ari Silvennoinen Hannu Saransaari Samuli Laine Jaakko Lehtinen Remedy Entertainment Aalto University Umbra Software NVIDIA NVIDIA Aalto University

Coping with Scene Complexity We want to render more than we can afford In real-time graphics, we often want to render more than we can afford. For example, in Quantum Break, a Xbox One title I m currently working on, we typically have 10 or 20 million triangles in a scene and a budget of just a few million triangles per frame.

Coping with Scene Complexity We want to render more than we can afford Need to use visibility culling and level-of-detail techniques To cope with this amount of geometry, we need to use visibility culling and level-of-detail techniques, which are orthogonal methods for reducing the number of triangles rendered per frame. In this talk, we ll consider only visibility culling.

Visibility Culling Given a scene and a camera, visibility culling is the process of identifying and removing the hidden parts of the scene from the renderer.

Visibility Culling There are many ways to accomplish this but we typically start by rendering the occluders to a depth buffer.

Visibility Culling And then we test the bounding box of each scene object against the depth buffer.

Visibility Culling This way we find out which objects are potentially visible and need to be rendered.

Problem Visibility algorithm needs to be faster than processing the whole scene In order for the visibility culling algorithm to be useful, it must be faster than processing the whole scene.

Problem Visibility algorithm needs to be faster than processing the whole scene Need simplified occluders; currently mostly manual work This had led to a situation, where artists need to manually create simplified occluders instead of working on the visuals, which is clearly not economical. This has been a commonplace practice since the late nineties and hence the lack of research in the area of occluder simplification in general 3D environments, a known problem for more than 15 years, is somewhat surprising.

For example, this is a detailed model of a train that we want to simplify.

And this is the hand-crafted, extremely simplified occluder that you might get from an artist. Our goal should look something like this.

Goal Automatic occluder simplification Given a display mesh and a budget of N triangles, generate simplified model with similar occlusion characteristics So, given all this, our goal is to take a crack at a fully automatic occluder simplification method. The problem we are solving can be stated as follows: given a display mesh and budget of N triangles, generate a simplified model with similar occlusion characteristics which satisfies the given budget constraints.

Goal Automatic occluder simplification Given a display mesh and a budget of N triangles, generate simplified model with similar occlusion characteristics Works with general 3D triangle soups It should be noted that the problem has a trivial solution: we could just pick a subset of the original triangles, and, in the late nineties, there actually were a few papers on how to do this in a principled manner. However, we don t assume any special structure of the input geometry. We take a general triangle soup as input, like this train for example, and don t really care about the size, orientation, or even the degeneracy of the input triangles.

Previous Work Most traditional rendering algorithms fire rays through each pixel Special path tracing, cases for etc. occlusion determine Subset of the intensity input [Coorg by and averaging Teller 1997], many [Wonka samples and Schmalstieg1999] (MC sampling) 2.5D urban scenes [Germs and Jensen 2001] sample all possible paths light can take from source to sensor Valid from small region only (e.g., hoops) [Brunet 2001] Simple, axis-aligned 3D scenes [Darnell 2011] Not useful for finding derivatives Difficult to generalize As mentioned, most of the direct previous work has been focused on solving special cases, all of which assume some special structure in the input geometry and therefore they are difficult to extend to handle the general 3D case.

Previous Work Most traditional rendering algorithms fire rays through each pixel General path tracing, mesh simplification etc. methods determine Simplification intensity envelopes by [Cohen averaging 1996] many samples (MC sampling) Quadratic error metrics [Garland and Heckbert 1997] sample all possible paths light can take from source to sensor Voxel-based [Nooruddin and Turk 2003] Textured tangent planes [Decoret 2003] Not useful for finding derivatives Focus on visual similarity which is not the same as occlusion There exists a large base of work related to general mesh simplification. Methods like Garlands s quadratic error metrics and the tangent plane approximation by Decoret have focused extensively on visual similarity.

Main Idea: Focus on Occlusion Instead of trying to match visual similarity, we focus directly on the occlusion properties. Let s consider this 2D, closed polygon. We want to find a simplified shape which has the same occlusion characteristics.

Let s take a look at a few rays. Main Idea: Focus on Occlusion

Main Idea: Focus on Occlusion

Main Idea: Focus on Occlusion

Main Idea: Focus on Occlusion We d like to have something simpler than the polygon which blocks the same rays.

Main Idea: Focus on Occlusion Interior slice is a conservative occluder If we cut the polygon with a line we observe that the same ray also intersects the interior line segment.

Main Idea: Focus on Occlusion Line soup and polygon have similar occlusion characteristics If we cut the polygon with more lines, we can block almost the same set of rays which are blocked by the original polygon: the line soup and the polygon have similar occlusion characteristics.

Main Idea: Focus on Occlusion Line soup and polygon have similar occlusion characteristics However, most of the lines are redundant, in the sense that they block the same rays, and by carefully choosing which cuts to use, we can obtain a simplified occluder. Note that this would be impossible with a general mesh simplification method.

Main Idea: Focus on Occlusion Focusing on occlusion gives us more freedom By focusing on occlusion instead of visual similarity, we have relaxed the problem of surface based simplification by allowing plane cuts, which gives us more degrees of freedom to exploit. And the same 2D principles generalise directly into 3D.

Algorith Sketch 1. Cut the model using a large number of planes 2. Assemble the cuts such they satisfy our budget and maximise occlusion similarity This can be turned into an algorithm as follows. First we cut the model with a large number of planes and then we assemble the plane cuts such that they satisfy the budget constraint and maximise the occlusion similarity.

But there is a big question: how do we measure occlusion? How to Quantify Occlusion?

Surface Area? < If we are looking at individual rays, then surface area is the right answer: bigger surface area means that more rays are blocked.

Surface Area? = However, in this case both objects have equal surface area, even thought the left one contains a lot of holes and is useless as an occluder because we can see through it. It s seems clear that surface area is not enough.

Topological Erosion Why is a sphere a better occluder than a torus? = To understand what s going on with all these holes, let s consider a 2D projection of a torus which has just a one hole and a sphere which has no holes at all. Note that the shapes have equal surface area just like in the previous example. If we perform a topological erosion over both shapes,

Topological Erosion Why is a sphere a better occluder than a torus?

Topological Erosion Why is a sphere a better occluder than a torus?

Topological Erosion Why is a sphere a better occluder than a torus?

Topological Erosion Why is a sphere a better occluder than a torus?

Topological Erosion Why is a sphere a better occluder than a torus? < We see that the erosion process eats the donut but just shrinks the sphere. This is a clue that we should look at the surface area after the erosion.

Measuring Occlusion Surface area after erosion And that s the basic idea of how we measure occlusion. For a fixed direction and erosion radius, we do an orthogonal projection into 2D, just like a shadow map, and perform topological erosion and compute the surface area after the erosion.

Measuring Occlusion Z Z 1 0 Surface area after erosion drd! And then we integrate this over all radii and directions to obtain a the total occlusion measure.

Algorithm Outline 1. Voxelize the input model and build a closed model with a well defined interior 2. Generate a large number of planar polygons by sampling the interior of the voxel model 3. Assemble the polygons such that they satisfy our budget and maximise total occlusion measure So now that we have a practical and a principled way to measure occlusion, we can finish fleshing out the algorithm sketch we had before. We start by voxelizing the input geometry, which guarantees that we have a well defined interior so we can form valid plane cuts.

Algorithm Outline 1. Voxelize the input model and build a closed model with a well defined interior 2. Generate a large number of planar polygons by sampling the interior of the voxel model 3. Assemble the polygons such that they satisfy our budget and maximise total occlusion measure Then we generate a large number of candidate polygons by cutting the voxel mesh with random planes.

Algorithm Outline 1. Voxelize the input model and build a closed model with a well defined interior 2. Generate a large number of planar polygons by sampling the interior of the voxel model 3. Assemble the polygons such that they satisfy our budget and maximise total occlusion measure Finally, we assemble the polygons together to obtain the simplified occluder. Let s walk through each of the three parts in more detail.

1. Voxelization We begin by voxelizing the input geometry using accurate triangle-aabb intersection tests. This discretization step introduces some error but it is bounded by voxel resolution. After the voxelization, we flood-fill the solid interior and finally generate a closed, 2-manifold boundary mesh from the exterior faces.

2. Interior Sampling Next we generate a large number of plane cuts by sampling the space of directions and depths. For each direction, we stratify the depth range into depth bins.

2. Interior Sampling Interior slice And for each bin we sample the depth range by rasterising the interior of the solid voxel mesh and pick the interior slice with maximal surface area.

2. Interior Sampling Rasterized interior slice Polygons Next we convert the rasterised plane cuts into polygons by running this pipeline which converts the bitmap into edge loops and simplifies the topology in order to generate a set of polygons for each bitmap.

3. Occluder Assembly The interior sampling produced a large number of candidate polygons, each of which is a valid occluder. But as we saw previously, most of the polygons are redundant and now we need to choose the best ones based on the occlusion measure.

3. Occluder Assembly Use a greedy method to pick one polygon at a time Evaluate total occlusion measure for each possible choice and choose the maximal one Iterate the process until the occluder is complete We use a greedy method to pick one polygon at a time. We evaluate the occlusion measure for each possible choice and choose the maximal one. This process is iterated until the occlusion measure does not change much when adding new polygons to the occluder.

3. Occluder Assembly The resulting occluder might still exceed our triangle budget Remove triangles one-by-one until we reach our budget The resulting occluder might still exceed our budget, so the final step is to progressively remove triangles from the polygons until we have met the budget.

Bunny 5K Let s take a look at some results. Here is the bunny with 5 thousand triangles and the simplified occluder with 64 triangles. The bottom row shows the occluder superimposed on the model in various view angles in yellow.

Buddha Input 1087474 tris Output 64 tris And here is the Buddha. You can see that the resulting occluders respects the holes around the arms in the original model.

Machine Input 394452 tris Output 64 tris And here is the machine.

Dragon Input 871306 tris Output 64 tris And here is the dragon.

Surface Area vs. Occlusion Measure Input Surface Area Occlusion Measure Here is a comparison of using surface area instead of the occlusion measure as we described. The occluder built by choosing polygons based on their surface area instead of occlusion measure has several holes in it from which we can see through. We also did a statistical precision-recall analysis of the occlusion properties between surface area and the occlusion measure and it showed that occlusion measure is consistently better than surface area. You can find the details in the paper.

Comparison against Oxel Input 28 tris Ours 6 tris Oxel 509 tris [Darnell 2011] Here is a comparison against Oxel which shows that our method is not sensitive to the orientation of the input geometry.

Difficult Input Input 100K tris Ours 64 tris Comparison And here is an example which shows that our method is robust and can produce reasonable results even for difficult input models.

Hierarchical extension Straightforward extension to handle large scenes Build a BVH over the input geometry and apply the algorithm to each node separately Finally, it is straightforward to extend the method to handle large scenes by first building a bounding volume hierarchy over the input geometry and then applying the basic method to each hierarchy node in isolation.

Let s take a look at a video. Here you can see the hierarchical occluders on the left and the original scene on the right.

Conclusions and Future Work Principled way to quantify occlusion Fast evaluation based on Euclidean Distance Transform Scalable method for occluder simplification Works with general triangle soups To sum up, we presented a principled way to quantify and evaluate occlusion together with a scalable and general method for occluder simplification.

Conclusions and Future Work Principled way to quantify occlusion Fast evaluation based on Euclidean Distance Transform Scalable method for occluder simplification Works with general triangle soups Could we apply the occlusion measure / simplified occluders to other problems? Light ray connections in path tracing? BVH build heuristics? Finally, we may ask if we could apply the occlusion measure or the simplified occluders in other problem domains, and with that, I ll conclude my talk.

Thank You! Acknowledgments Anonymous reviewers for constructive and thorough feedback

Bounded Approximation Error Sources of error Voxelization error (bounded by voxel size) Rasterization error (bounded by raster resolution) Edge loop simplification error (bounded by tolerance) Single user parameter: Voxel resolution Raster resolution and edge loop simplification set accordingly

Effect of Scale-Sensitive Discretization 16x16x16 32x32x32 64x64x64 128x128x128

Comparison to Other Methods

Fast Evaluation of the Occlusion Measure Directional occlusion is connected to Euclidean Distance Transform Gives a practical way to calculate the occlusion measure The directional occlusion measure is directly connected to Euclidean Distance Transform. And this is great news, because it gives us a practical and efficient way of evaluating the occlusion measure. The details can be found in the paper.

Hierarchical extension Input Hierarchical Occluder And here you can see a side-by-side image showing a large scene and a the hierarchical occluder.