accelerating sphere tracing
play

Accelerating Sphere Tracing Csaba Blint , Gbor Valasek Etvs Lornd - PowerPoint PPT Presentation

Accelerating Sphere Tracing Csaba Blint , Gbor Valasek Etvs Lornd University, Hungary Table of Contents Introduction to Sphere Tracing Relaxed Sphere Tracing Current best Enhanced Sphere Tracing Our first contribution


  1. Accelerating Sphere Tracing Csaba Bálint , Gábor Valasek Eötvös Loránd University, Hungary

  2. Table of Contents ➢ Introduction to Sphere Tracing ✓ Relaxed Sphere Tracing Current best ➢ Enhanced Sphere Tracing Our first contribution ✓ Optimally approximates smooth surfaces ✓ ~50% faster than relaxed sphere tracing ➢ Iteratively Increasing Resolution Our second contribution ✓ Increases resolution while rendering ✓ ~20% speedup 2 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  3. Ray-Surface Intersection • 𝒒 is a surface point  implicit representation  𝑔 𝒒 = 0 • Ray: 𝒕 𝑢 = 𝒒 0 + 𝑢 ⋅ 𝒘 0 • Ray-surface intersections: 𝑔 𝒕 𝑢 = 0 3 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  4. Singed Distance Function • 𝑔(𝒒) : signed distance to the surface from point 𝒒 Unbounding sphere → Center: 𝒒 0 → Radius: 𝑔(𝒒 0 ) 4 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  5. Sphere Tracing Step • Travel 𝑔(𝒒) on ray – Cannot step over an intersection 5 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  6. Repeat: t += 𝑔 𝒒 0 + 𝑢 ⋅ 𝒘 0 ; ▪ Sphere Tracing Algorithm Stop: ▪ o After a 100 iterations • Travel 𝑔(𝒒) on ray – Cannot step over an intersection o When 𝑔 𝒒 0 + 𝑢 ⋅ 𝒘 0 is small o When 𝑢 is large [1] HART J. C.: Sphere tracing: A geometric method for the antialiased ray tracing of implicit surfaces. The Visual Computer 12 (1994), 527 – 545 6 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  7. SDFE – Signed Distance Function Estimate • 𝑔(𝒒) is a lower bound to the actual distance [1] HART J. C.: Sphere tracing: A geometric method for the antialiased ray tracing of implicit surfaces. The Visual Computer 12 (1994), 527 – 545 7 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  8. Slowdown • Large overlap – could have taken a larger step 8 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  9. Relaxed Sphere Stracing • Take a 1.6 x larger step • Check if spheres overlap • Step back if they don’t [2] KEINERT B., Schäfer H., Korndörfer J., Ganse U., Stamminger M.: Enhanced Sphere Tracing. The Eurographics Association (2014) 9 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  10. Divergent case – Sphere Tracing • 11 tracing steps • 11 function evaluations 10 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  11. Divergent case – Relaxed Sphere Tracing • 11 tracing steps • 13 function evaluations 11 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  12. Divergent case – (Our) Enhanced Sphere Tracing • 11 tracing steps • 12 function evaluations 12 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  13. Enhanced Sphere Tracing Step I • Idea: Approximate flat surfaces optimally Previous 𝑠 𝑗−1 Next ? 𝑠 𝑗 13 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  14. Enhanced Sphere Tracing Step II • Unbounding sphere is expected to touch ✓ The previous unbounding sphere ✓ The flat surface Next step size to try: 𝑒 𝑗+1 = 𝑠 𝑗 + 𝑠 𝑗+1 𝑒 𝑗 𝑠 𝑗 𝑠 𝑗−1 𝑠 𝑗+1 𝑠 𝑗 𝑠 𝑗+1 = ? Tangent 14 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  15. Enhanced Sphere Tracing Step III Solution: 𝑗 ⋅ 𝑒 𝑗 − 𝑠 𝑗−1 + 𝑠 𝑗 𝑠 𝑗+1 = 𝑠 𝑒 𝑗 + 𝑠 𝑗−1 + 𝑠 𝑗 Next step size to try: 𝑒 𝑗+1 = 𝑠 𝑗 + 𝑠 𝑗+1 What if the surface is curved? 𝑒 𝑗 Similar 𝑠 𝑗 Triangles 𝑠 𝑗−1 𝑠 𝑗+1 𝑠 𝑗 𝑠 𝑗+1 15 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  16. Enhanced Sphere Tracing Step – Relaxation Relax enhanced step: 𝑒 𝑗+1 = 𝑠 𝑗 + 𝜕 ⋅ 𝑠 𝑗+1 Eg.: 𝜕 = 0.9 relaxation parameter. Different goal: fix slight concavity  Optimal on smooth surfaces 𝑒 𝑗 𝑠 𝑗 𝑠 𝑗−1 𝑠 𝑗+1 𝑠 𝑗 𝑠 𝑗+1 16 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  17. Test Scene I: CSG composition 17 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  18. Test Scene II: Village Accelerating Sphere Tracing , Csaba Bálint, Valasek Gábor 18

  19. Non-smooth surface! Scene III: Mandelbulb 3D Fractal 19 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  20. Enhanced Sphere Tracing: Relative runtimes Classic ST Faster than relaxed ST But why? • 20 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  21. Enahnced Sphere Tracing: Step back rato Enhanced sphere tracing → Only a few fallbacks → Better thread coherence → Even faster on the GPU Ratio of overshoots visualized White pixels: • 100% wrong prediction Black pixels: • 100% good prediction 21 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  22. Enhanced Sphere Tracing: Relative Error Close to the surface our algorithm overtakes 22 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  23. Enhanced Sphere Tracing: Relative Performance 1.6 times better than Relaxed ST 23 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  24. Cone Tracing Unbounding sphere [1] HART J. C.: Sphere tracing: A geometric method for the antialiased ray tracing of implicit surfaces. The Visual Computer 12 (1994), 527 – 545 24 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  25. Iteratively Increase Resolution 4 new cones penetrate the scene further 25 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  26. Iteratively Increasing Resolution Results Multiple resolution change is expencive Baseline: single res. Using 2 different resolutions: 20% 26 Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

  27. Summary ➢ Enhanced Sphere Tracing ✓ Optimally approximates smooth surfaces ✓ 50% faster than relaxed sphere tracing ➢ Iteratively Increasing Resolution ✓ Increases resolution while rendering ✓ 20% faster & Interactive or real-time rendering Thank you for your attention! [1] HART J. C.: Sphere tracing: A geometric method for the antialiased ray tracing of implicit surfaces. The Visual Computer 12 (1994) [2] KEINERT B., Schäfer H., Korndörfer J., Ganse U., Stamminger M.: Enhanced Sphere Tracing. The Eurographics Association (2014) Accelerating Sphere Tracing , Csaba Bálint, Gábor Valasek

Recommend


More recommend