Clipless Dual-Space Bounds for Faster Stochastic Rasterization Samuli Laine Timo Aila Tero Karras Jaakko Lehtinen NVIDIA Research
(x,y)
(x,y,u,v,t)
Motion Blur
t=0t=1
Motion Blur
t Accumulation Buffer [Haeberli ‘90]
t InterleaveUVT [Fatahalian ‘09]
t
t
t
4 samples/pixel (16 UVT triples)16 samples/pixel (64 UVT triples) Scene: Assassin’s Creed, courtesy of Ubisoft InterleaveUVT [Fatahalian ‘09]
Unique UVTs 4 samples/pixel, unique UVTs16 samples/pixel, unique UVTs Scene: Assassin’s Creed, courtesy of Ubisoft
5D Rasterization t=0t=1 t
5D Rasterization t=0t=1 t
5D Rasterization t=0t=1 t
5D Rasterization t
t=0t=1 t ?
5D Rasterization t=0t=1 t
5D Rasterization t=0t=1 t ?
5D Rasterization t=0t=1 t ?
Pixar Algorithm t=0t=1 t t=.5
Pixar Algorithm t=0t=1 t t=.5 XX
Pixar Algorithm t=0t=1 t t=.5 XX
Our Method t=0t=1 t
Our Method t=0t=1 t
Our Method t=0t=1 t XXX t range computed for pixel
Our Method Determine pixels potentially covered by triangle For each pixel Compute time bounds t min,t max Enumerate samples where t min ≤ t ≤ t max For each such sample, perform 5D coverage test Same for lens bounds u min,u max and v min,v max
Bound Computation Lens bounds computed in screen space Time bounds computed in dual space
Lens Bounds x y u=0u= –1u= +1 film lens focal plane u screen-space x is linear with u
Lens Bounds x y u= –1u= +1 screen-space x is linear with u
Lens Bounds x y u=au=b screen-space x is linear with u u a b
Time Bounds World-space affine motion Not affine in screen space, but affine in clip space Perspective causes singularities in screen space Operate in dual space
Clip Space and Dual Space x w t=0 t=1
Clip Space and Dual Space x w γ δ γ= –1 γ= +1
Clip Space and Dual Space x w γ δ δ { γ= –0.5
Clip Space and Dual Space x w γ δ
x w γ δ
x w γ δ
x w γ δ δ is linear in x and w δ = x – wγ x and w are linear in t δ is linear in t t=0 t=1 t=0 t=1
Clip Space and Dual Space x w γ δ t=0 t=1 t=0 t=1
Clip Space and Dual Space x w γ δ t=0 t=1 t=0 t=1
Clip Space and Dual Space x w γ δ t=0 t=1 t=0 t=1 t=a t
Clip Space and Dual Space x w γ δ t=0 t=1 t=0 t=1 t=a t a
Time Bounds Compute separately for x and y Intersect resulting spans If intersection is empty, skip pixel
Recap For each triangle For each pixel Compute t, u, v bounds Cull samples outside bounds Profit
Results Measure sample test efficiency (STE) Compare against methods that allow arbitrary sampling patterns # samples tested with full 5D test # samples hit STE =
Results Scene: Age of Conan PC MMO, courtesy of Funcom Bbox scan Pixar Our method static23.6 motion motion x defocus defocus x both both x STE in %, scene Conan
Results Scene: Assassin’s Creed, courtesy of Ubisoft Bbox scan Pixar Our method static23.2 motion motion x defocus defocus x both both x STE in %, scene Assassin
Results Bbox scan Pixar Our method static motion motion x defocus defocus x both both x STE in %, scene Cars
Conclusions Each triangle processed once Arbitrary sampling patterns High STE Future work Combined motion + defocus case
Thank You