Download presentation
Presentation is loading. Please wait.
1
Optimized Subdivisions for Preprocessed Visibility Oliver Mattausch, Jiří Bittner, Peter Wonka, Michael Wimmer Institute of Computer Graphics and Algorithms Vienna University of Technology
2
Set of objects Object space subdivision Set of view cells View space subdivision For each view cell: Compute potentially visible set (PVS) Runtime Locate view cell Render PVS Oliver Mattausch 1 Visibility Preprocessing That’s what we are optimizing
3
2 objects3 objects4 objects Example: Object Space Subdivision Oliver Mattausch 2 Result: Set of objectsStart: 1 object (=scene) OBJ 1 OBJ 2 OBJ 3 OBJ 4
4
Oliver Mattausch 3 Example: View Space Subdivison VC3 View space VC1VC2 VC4 Result: Set of view cells Occluder
5
Oliver Mattausch 4 Object / View Space Subdivision City scene Object space subdivision View space subdivision
6
First subdivide object space Then subdivide view space Oliver Mattausch 5 Previous Approach VC1 VC3 VC2 VC4 View Space Occluder Triangle soup
7
Object space subdivision Bounding volume hierarchy (BVH) Surface area heuristic (SAH) View space subdivision kD-Tree Visibility-Driven View Space Construction [Mattausch06] Oliver Mattausch Previous Approach BVH Parent bounding box 6
8
Oliver Mattausch 7 Visibility-Based View Space Construction BSP [Teller 92]Visibility-Based LowHigh Render cost
9
Motivation Focus of previous work either on Object space subdivision View space subdivison But the problem is interconnected! Oliver Mattausch 8 VC3 VC1VC2 VC4
10
Object space subdivision too shallow Oliver Mattausch 9 Motivation: Previous approach VC1VC2 VC4 View Space High render cost VC3 Triangles per view cell: 4.5 Objects per view cell: 1
11
Object space subdivision too deep + High render cost (setup cost per object!) Oliver Mattausch 10 Motivation: Previous approach VC1 VC3 VC2 VC4 View Space High storage cost Triangles per view cell: 2.25 Objects per view cell: 2.25
12
Object space subdivision optimal Oliver Mattausch 11 Motivation: Previous approach VC1 VC3 VC2 VC4 View Space Low render + storage cost Triangles per view cell: 2.25 Objects per view cell: 1
13
Motivation Previous approach Object space subdivision: Can be too shallow / too deep View space subdivision cannot fix this! Our approach Interleave view and object space splits
14
Oliver Mattausch 13 Our Approach: Interleaved Subdivisions We search optimal combined subdivisions for a given memory budget Very complex problem greedy algorithm Treat view / object space splits equally Apply next best split Either view or object space
15
Oliver Mattausch 14 Example: Sphere through hole LowHigh Render cost Sphere View space - algorithm subdivides high render cost regions - algorithm subdivides only visible front Sphere can be seen only through hole
16
Oliver Mattausch 15 Our Approach: Outline 1.2. 1. Visibility sampling Estimate render cost 2. Interleaved subdivisions Interleave view and object space splits
17
Oliver Mattausch 16 Visibility Sampling Fast stochastic sampling Casts rays from viewpoints towards scene objects Coarse estimate of visibility View space = scene bounding box View space = distant region
18
Oliver Mattausch 17 Render Time Heuristics Minimize expected rendering time S = set of view cells p = probability of view point inside a view cell (~volume of view cell) r = render time estimate [Wimmer03] c = expected rendering time (cost to minimize)
19
Objects seen from both parts Memory cost increase Compute render cost decrease due to split Oliver Mattausch 18 View Space Split: Evaluation Left PVS: 6 objectsRight PVS: 6 objects View cell Visibility sampling Split plane Obj PVS: 8 objects Occluder
20
Oliver Mattausch 19 Object Space Split: Evaluation Dual to view space split View cells which see only one side of the split: Reduction of # triangles in PVS
21
Oliver Mattausch 20 Interleaved Subdivisions Each split (view / object) induces Render cost decrease Memory cost increase Leaves of view or object space hierarchy: Compute local split plane Candidates for the next split View space hierarchyObject space hierarchy Split candidates
22
Oliver Mattausch 21 Interleaved Subdivisions Decrease render cost until memory budget is reached Related to knapsack problem Items: Candidates for next split Benefit: Render time decrease Cost: Memory cost increase
23
Object space Priority queue of candidates for a split Priority p = dR / dM dR = render time decrease dM = memory cost increase Apply next best split: Oliver Mattausch 22 Interleaved Subdivisions Render cost Memory Object space split View space split View space Limit
24
Oliver Mattausch 23 Interleaved Subdivisions: Complexity Each split affects other candidates for a split Full reevaluation would be very costly We use some optimizations Object space split - affects all view cells which see this object
25
Oliver Mattausch 24 Optimized Algorithm 1.Start with very coarse object space subdivision Use surface area heurisic Alternatively, split by materials, size 2.Choose next best split (view or object) 3.Apply batch of splits From either view or object space 4.For split candidates affected by previous splits Reevaluate some random candidates
26
Oliver Mattausch 25 Results Our method vs. previous approach Previous approach: Sequential subdivision (SEQ-n) First object space (n objects) Then view space [Mattausch et al. EGSR06] Our method: Interleaved subdivisions ( INT) All methods: Subdivide until memory budget is reached
27
Oliver Mattausch 26 Results Arena 1.5M triangles Coarse visibility: 5M visibility samples 30 MB memory budget Evaluation: We use the full visibility solution
28
Oliver Mattausch 27 Results Arena Render cost Memory cost (MB) 4.45 2.74 2.72 Speedup of 2.72 – 4.45
29
Oliver Mattausch 28 Results Arena: Timings MethodTime [min] SEQ-1K10.3 SEQ-30K10.8 SEQ-60K11.0 INT30.3
30
Oliver Mattausch 29 Conclusions View and object space subdivisions interconnected Interleave subdivisions Greedy algorithm for solving complex problem Coarse estimate of visibility Good results with 5M samples or more Further investigate required sample density Adaptive version
31
Funded by GameTools Project Leading edge 3D research Geometry/Plants, Visibility, Illumination C++ & Direct3D 9/OpenGL Free for European companies www.gametools.org Oliver Mattausch 30
32
Oliver Mattausch 31 Optimized Subdivisions Thank you for your attention!
33
Oliver Mattausch 32 Results Arena Ratio view / object space splits # Splits
34
Object Space Split: Evaluation View cells seeing object View cells see both parts View cells see left part View cells see right part Visibility samplingSplit plane Object 33 Oliver Mattausch Occluder
35
Oliver Mattausch 34 Results Arena (Parameter set 1) Render cost Memory cost (MB) 1.22 1.72 3.08 Speedup of 1.22 – 3.08
36
Oliver Mattausch 35 Results Arena Ratio view / object space splits # Splits
37
Oliver Mattausch 36 Results Arena: Statistics MethodTime [min]View cellsObjects SEQ-1K10.3298001000 SEQ-30K10.8320030000 SEQ-60K11.0180060000 INT30.3552816272
38
Oliver Mattausch 37 Visibility-Based Object Splits Use visibility-based heuristics for local split Place split plane with respect to minimal cost Sweep algorithm for finding split plane
39
Render Time Heuristics Render time estimate Plug in any suitable model E.g., a simple model: max (a * # triangles, b * # objects, c * # pixels) Fit parameters to requirements of the engine Oliver Mattausch 38
40
Objects seen from both parts Memory cost increase Compute render cost decrease due to split Oliver Mattausch 39 View Space Split: Evaluation Left PVS: 6 objectsRight PVS: 6 objects View cell Visibility sampling Split plane Obj PVS: 8 objects Occluder
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.