Upload
others
View
1
Download
0
Embed Size (px)
Citation preview
ITERATIVE DEPTH WARPING
Sungkil LEE* Younguk KIMSungkyunkwan University (SKKU), South Korea
Elmar EISEMANNDelft University of Technology, Netherlands
3© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Depth Buffer
• A fundamental basis for modern GPU rendering pipeline• Many visibility-related operations
• e.g., shadows, GI, occlusion culling, ambient occlusion, ...
• Typically created in a full rendering pass
• Research Goal: Early Access to Depth Buffer• Depth-buffer prediction beneficial in many scenarios
4© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Example: Occlusion Culling
• 6x faster (6.2 ms for 110M Tris., 94K objs., GTX1080)
5© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Our Solution: Warping
• Depth-Buffer Warping• previous solutions mostly successful for color images
• depth buffer needs to be precise/conservative
• Challenge: real-time high-quality warping• More precisely, backward warping
6© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Forward vs. Backward Warping
• Forward warping splats source pixels 𝐩 (with motion vector) to destination pixels 𝐪.
• Backward warping gathers 𝐩 whose motions can displace to 𝐪.
𝐪𝐩𝑞 = 𝑇(𝑝)
𝑝 = 𝑇−1(𝑞)𝐩 𝐪
7© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Forward vs. Backward Warping in GPU
Pros Cons
Forward warping
• knows desination pixels to write • GPU-unfriendly (splatting or atomics)• holes may appear
Backward warping
• GPU-friendly (only texturelookups), and usually faster
• no holes (when source exists)• Preferred in general
• Need non-trivial search when source pixels are unknown (arbitrary motions)
8© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Our Contributions
• Our solution builds upon the previous image warping• Iterative Image Warping [Bowles et al. 2011]
• but, for warping of depth buffer
• Our solution improves on:• purely backward-only warping
• efficient bounding of backward search area
• multi-layer warping for depth hole filling
Related Work and Background
10© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
• Temporal cache of shading values [Nehab et al. 2007]• Reverse repojection can reuse shading
• still requires geometry pass
Temporal Coherence
11© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
• Post-rendering 3D Warping [Mark et al. 1997]• Forward mapping of per-pixel primitives for reference frames
Multi-Source Image Warping
Reference Frame #1
Reference Frame #2
Composite
3D Warp
3D Warp
12© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Multi-Source Image Warping
• Bidirectional reprojection [Yang et al. 2011]• Disocclusion holes filled with bidirectional B-frames
• Delay in frame time
13© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Single-Source Image Warping
• Grid-based forward warping• Temporal upsampling, stereo-view synthesis [Didyk et al., 2010a, b]
• Coarse/adaptive grid subdivision
[Didyk 2010a] [Didyk 2010b]
14© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Single-Source Image Warping
• Fast backward warping [Andreev 2010]• Mostly for background
• Simple inpainting: replication from neighboring patches
• Suitable for frame rate upsampling
15© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Single-Source Image Warping
• Fixed-point iteration [Bowles et al., 2011]• Backward warping formulated as fixed-point iteration
• Hybrid warping: forward pre-warping + backward warping
• Costly tessellation required
16© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Background: Fixed-Point Iteration (FPI)
• A fixed point 𝒙 of function 𝑔 satisfies: 𝒙 = 𝑔(𝒙).• FPI 𝒙n+1 ← 𝒈(𝒙n) converges to 𝒙 = 𝑔(𝒙)
• when 𝑔 is differentiable around 𝒙 and |𝑔′ 𝒙 | < 1.
y = x
y = g(x)
y
x
!
Our Approach
18© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Inputs
• Depth buffer 𝒁 and motion buffer 𝑽• from the previous frame or the known view
• Readily available in deferred rendering pipeline
Depth buffer 𝑍 Motion vector 𝑉
19© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Outputs
• Estimated depth buffer ො𝒛 at novel views• Hole filling used optionally, depending on applications
Conservative without hole filling With multi-layer hole filling
20© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Backward Warping with FPI
• Given a destination pixel 𝐩, FPI on source pixels 𝐪:
𝐪i+1 ← 𝑤(𝐪i) ∶= 𝐩 − 𝑣(𝐪i)
• Iteration stops at a fixed point 𝐪 = 𝑤(𝐪). In other words, 𝐪displaces to 𝐩:
𝐪 + 𝐯(𝐪) = 𝐩
21© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Simple Example
• Choose the closest among multiple solutions
• For a smooth surface, 2—3 iteration is enough
Search seeds
p: destination in novel viewNo motion!
Solution
22© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Problems
• Seed 𝒒0 is crucial.• A simple 𝑞0 = 𝑝 may fail at boundaries between different motions
• Convergence can be guaranteed:• with 2×2 Jacobian matrix of 𝑤 [Bowles 2012]
• but, requires costly fine tessellation and pre-warping
23© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Our solution
• Stratified sampling in compact local search regions Ω
Global search boundLocal search bound
24© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Our solution
• Stratified sampling in compact local search regions Ω• May not be precise for a complex scene
• Practically, higher sampling density leads to convergence.
• Motion bound query: use min-max mipmaps• min/max of (x,y) motion can be encoded in 4-channel texture
• vec4( xmotion_min, xmotion_max, ymotion_min, ymotion_max )
• Refer to the paper for the pseudocode
25© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Results: Single-Layer Warping
• Set background depth for depth holes (disocclusions)• Conservative estimation
26© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Multi-layer Warping for Depth Hole Filling
• We may use conservative estimation (e.g., occlusion culling)• But, we may need to fill the holes for a higher accuracy
• Our solution: multi-layer inpainting• Repeat search for hidden layers
27© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Generating Hidden Layers
• Depth peeling [Everitt 2001]
28© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Generating Effective Hidden Layers
• Depth peeling often requires too many layers• Effective reduction of layers: peeling of only visible objects
• We generalize lens umbra culling [Lee 2010] for motions
Depth peeling threshold
Known view
Novel view
Umbra
29© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Depth Peeling with Umbra Culling
• Reduces ~2 layers for similar warping quality
30© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Results: Multi-Layer Warping
• Useful for multiview rendering (e.g., soft shadows)
Experimental Analysis
32© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Test Configurations
• Experimental configurations• NVIDIA GTX 1080, Full-HD (1920×1080), OpenGL 4.5
• Four camera-animated scenes (8.5M—110M faces, 17—94K objects)
33© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Search Seed Samples (N) and Layers (L)
• More samples/layers give better results (PSNR/SSIM)• L=1 (single-layer): good, except for depth holes
• L=4 (multi-layer): try to saturate N≥4 (37 dB, 0.997)
• Practical speed/performance tradeoff: N=[8,16]
N=4 N=8 N=16 N=32N=1 N=2 REF
20
.2 /
0.8
26
31
.7 /
0.9
8
22
/ 0
.88
33
7 /
0.9
97
21
/ 0
.84
34
/ 0
.99
1
21
/ 0
.84
83
7 /
0.9
97
21
/ 0
.85
73
6 /
0.9
97
22
/ 0
.87
63
7 /
0.9
98
L=1
L=4
34© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Quality Comparison with Forward Warping
• Two common forward warping techniques• VFW (Vertex-based FW): vertex-to-quad splatting
• AFW (Atomics-based FW): direct writes with compute shader
• Results (averaged on all the animation sequences)• Ours: similar SSIM, but much higher in PSNR (better pixel accuracy)
Ours (N=16) Vertex FW Atomics FW
PSNR SSIM PSNR SSIM PSNR SSIM
L=1 (single-layer) 28.1 dB 0.977 24.0 dB 0.958 24.2 dB 0.966
L=4 (multi-layer) 34.3 dB 0.997 28.1 dB 0.997 27.4 dB 0.992
35© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Number Iteration (T)
• T=2—3 suffices for moderate motions, but requires more iteration for rapid motions
T=1 T=2 T=4 T=8 T=16
1X (29 px / frame)
0.980/22.7 0.999/34.9
0.997/34.3 0.999/34.3 0.999/34.3
0.906/13.6 0.998/32.5 0.998/32.5
0.588/4.7 0.924/11.6 0.993/34.2 0.995/34.2
0.856/12.3
0.467/4.3
0.210/1.5
0.999/34.9 0.999/34.9 0.999/34.9
0.999/34.3
0.998/32.5
avg. of max motion
2X (62 px / frame)
4X (141 px / frame)
8X (336 px / frame)
36© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Warping Performance
• Ours: less than 1 ms• additional 0.1 ms, when needing motion generation.
• Comparison with FW• Much faster than classical VFW
• Slightly slower than newer AFW (0.38—0.45 ms)
Ours (N=16) Vertex FW Atomics FW
L=1 0.68 ms 2.2 ms 0.30 ms
L=4 0.93 ms 6.2 ms 0.48 ms
Application: Occlusion Culling
38© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Hierarchical Occlusion Mapping Revisited
Object-space boundScreen-space bound Max-depth query(N-buffers)
Min-depth query(bounding corners)<
Occlusion culled
39© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Warping-based Occlusion Culling (WOC)
• Use the estimated depth buffer for HOM• No need to distinguish occluder/occludee, unlike the classical ones
• L=1 sacrifies the culling for depth holes
• But, its negligible overhead eventually improves performance
40© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
14.6
4.5
2.2
15.4
27.1
• Balloons (33M Tris., 35,200 objects)
WOC Performance
OURSCHC++VFCNOCULL IDEAL
41© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
38.4
43.8
18.3
6.2
4.2
WOC Performance
• Cityblock (110M Tris., 94,275 objects)
OURSCHC++VFCNOCULL IDEAL
Application: Soft-Shadow Mapping
43© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Speed-up of 1—30X
• More efficient for: complex scenes, many lights, smaller maps
Limitations and Conclusion
45© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Limitations
• Rapid motions and flipping triangles• e.g., faster than ~200 pixels per frame
• Practical remedy: dilation around neighbors
w/o dilation dilation
46© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Limitations
• Sub-pixel accuracy• From the rasterized pixel precision
• Rapid motion vectors amplify the errors
• Image periphery• Need to extend the image FOV during the capture
47© 2019 SIGGRAPH. ALL RIGHTS RESERVED.
Conclusion
• Scalable high-quality depth warping, based on• tight bounding technique for pure backward warping
• multi-layer depth hole filling
• Suitable for real-time GPU rendering• Scalable warping-based occlusion culling (WOC)
• Potentially useful many multi-view rendering scenarios• Depth-of-field, anti-aliasing, intra-frame reprojection for VR
Thank you for attention!