Presentation is loading. Please wait.

Presentation is loading. Please wait.

RT08, August ‘08 Large Ray Packets for Real-time Whitted Ray Tracing Ryan Overbeck Columbia University Ravi Ramamoorthi Columbia University William R.

Similar presentations


Presentation on theme: "RT08, August ‘08 Large Ray Packets for Real-time Whitted Ray Tracing Ryan Overbeck Columbia University Ravi Ramamoorthi Columbia University William R."— Presentation transcript:

1 RT08, August ‘08 Large Ray Packets for Real-time Whitted Ray Tracing Ryan Overbeck Columbia University Ravi Ramamoorthi Columbia University William R. Mark University of Texas at Austin Intel Corporation

2 RT08, August ‘08 Current Real-time Ray Tracing  Use large ray packets (16-256 rays)  Focused on primary visibility and point-light shadows  Images somewhat dull  Easily generated using rasterization algorithms

3 RT08, August ‘08 This Work: Whitted Ray Tracing  Whitted Ray tracing:  Primary Visibility  Point-light Shadows  Reflections  Refractions

4 RT08, August ‘08 Mission  Study large ray packets for Whitted ray tracing  Scene traversal (BVH)  Partition Traversal: New!  Frustum Culling  General secondary ray packets: New!

5 RT08, August ‘08 Mission  Evaluation of old and new algorithms  Ray packet size  Scene complexity  Ray Recursion Complexity

6 RT08, August ‘08 Result: Real-time Whitted RT

7 RT08, August ‘08 Outline  Motivation  Frustum Culling for Secondary Rays  Scene Traversal with Large Ray Packets  Results

8 RT08, August ‘08 Frustum Culling  Primary Rays  Reshetov et al. 2005  Point-Light Shadow Rays  Boulos et al. 2006, Wald et al. 2007  Reflection + Refraction Rays  New!

9 RT08, August ‘08 Frustum Culling: Point Light 1.Choose dominant axis: 2.Find intersection points at. 3.Get min/max coords. 1

10 RT08, August ‘08 1.Choose dominant axis: 2.Find intersection points at. 3.Get min/max coords. 4.Create 4 corner rays. 5.Compute plane normals. Frustum Culling: Point Light 1

11 RT08, August ‘08 Frustum Culling: Reflection

12 RT08, August ‘08 Frustum Culling: Reflection Samples’ Bounding Box Scene Bounding Box

13 RT08, August ‘08 Frustum Culling: Reflection 1.Choose dominant axis: 2.Find intersections with 2 planes: 1. from scene AABB. 2. from samples’ AABB. 3.Get min/max coords. 4.Create 4 corner rays. 5.Compute plane normals.

14 RT08, August ‘08 Outline  Motivation  Frustum Culling for Secondary Rays  Scene Traversal with Large Ray Packets  Results

15 RT08, August ‘08 3 Algorithms for Scene Traversal  Masked Traversal – Control Method  Based on Wald 2001, Reshetov 2005 (MLRT)  Only good for small packets  Ranged Traversal – State-of-the-art  Wald et al. 2007  Degrades performance for incoherent rays!  Partition Traversal: New!  Robust to incoherent rays and large packets

16 RT08, August ‘08 Scene Traversal  Use 2x2 ray packets as atomic ray primitive.  Group packets based on the image raster.

17 RT08, August ‘08 Masked Traversal 0 1 2 3 4

18 RT08, August ‘08 Masked Traversal 0 1 2 3 4 BVH Inner Cell

19 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Near BVH Leaf Cell

20 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Far BVH Leaf Cell

21 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Alive 0 1 2 3 4

22 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Alive 0 1 2 3 4

23 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Alive 0 1 2 3 4

24 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Alive 0 1 2 3 4

25 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Alive 0 1 2 3 4

26 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Alive Dead 0 1 2 3 4

27 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Alive Dead 0 1 2 3 4

28 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Alive Dead 0 1 2 3 4

29 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Alive Dead 0 1 2 3 4

30 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Dead Alive Dead 0 1 2 3 4

31 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Dead Alive Dead 0 1 2 3 4

32 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Dead Alive Dead 0 1 2 3 4

33 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Dead Alive Dead 0 1 2 3 4

34 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Dead Alive Dead 0 1 2 3 4

35 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Dead Alive Dead 0 1 2 3 4

36 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Dead Alive Dead 0 1 2 3 4

37 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Dead Alive Dead 0 1 2 3 4

38 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Dead Alive Dead 0 1 2 3 4

39 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Dead Alive Dead 0 1 2 3 4

40 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Dead Alive Dead 0 1 2 3 4

41 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Alive 0 1 2 3 4

42 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Alive 0 1 2 3 4

43 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Alive Dead 0 1 2 3 4

44 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Alive Dead 0 1 2 3 4

45 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Alive Dead 0 1 2 3 4

46 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Alive Dead Alive Dead 0 1 2 3 4

47 RT08, August ‘08 Masked Traversal 0 1 2 3 4 Dead Alive Dead 0 1 2 3 4  Causes extra ray—cell tests

48 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

49 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

50 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

51 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

52 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

53 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

54 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

55 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

56 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

57 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

58 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

59 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

60 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

61 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

62 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

63 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

64 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

65 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

66 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

67 RT08, August ‘08 Ranged Traversal 0 1 2 3 4

68 RT08, August ‘08 Ranged Traversal 0 1 2 4 3

69 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

70 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

71 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

72 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

73 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

74 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

75 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

76 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

77 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

78 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

79 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

80 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

81 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

82 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

83 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

84 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

85 RT08, August ‘08 Ranged Traversal 2 1 0 4 3

86 RT08, August ‘08 Ranged Traversal 2 1 0 4 3  Reduces ray—cell tests  Increases ray—triangle tests

87 RT08, August ‘08 Partition Traversal (New) 01234 2 1 0 4 3

88 RT08, August ‘08 Partition Traversal (New) 01234 2 1 0 4 3 A

89 RT08, August ‘08 Partition Traversal (New) 01234 2 1 0 4 3 ABE

90 RT08, August ‘08 Partition Traversal (New) 01234 2 1 0 4 3 ABE

91 RT08, August ‘08 Partition Traversal (New) 01234 2 1 0 4 3 ABE

92 RT08, August ‘08 Partition Traversal (New) 01234 2 1 0 4 3 ABE

93 RT08, August ‘08 Partition Traversal (New) 01234 2 1 0 4 3 ABE

94 RT08, August ‘08 Partition Traversal (New) 01234 2 1 0 4 3 ABE

95 RT08, August ‘08 Partition Traversal (New) 01432 2 1 0 4 3 ABE

96 RT08, August ‘08 Partition Traversal (New) 01432 2 1 0 4 3 ABE

97 RT08, August ‘08 Partition Traversal (New) 01432 2 1 0 4 3 A

98 RT08, August ‘08 Partition Traversal (New) 01432 2 1 0 4 3 A

99 RT08, August ‘08 Partition Traversal (New) 01432 2 1 0 4 3 ABE

100 RT08, August ‘08 Partition Traversal (New) 01432 2 1 0 4 3 ABE

101 RT08, August ‘08 Partition Traversal (New) 01432 2 1 0 4 3 ABE

102 RT08, August ‘08 Partition Traversal (New) 01432 2 1 0 4 3 ABE

103 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 ABE

104 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 ABE

105 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 A

106 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 A

107 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 A

108 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 A

109 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 A

110 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 A

111 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 A

112 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 ABE

113 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 ABE

114 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 ABE

115 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 ABE

116 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 A

117 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 A

118 RT08, August ‘08 Partition Traversal (New) 04132 2 1 0 4 3 A  More ray—cell intersection tests  No unnecessary ray—triangle intersection tests  Robust to incoherent rays

119 RT08, August ‘08 Outline  Motivation  Frustum Culling for Secondary Rays  Scene Traversal with Large Ray Packets  Results

120 RT08, August ‘08 Experimental Setup: System  Dual Quad-core 2.0 GHz Intel Xeon Processors (8 cores total).  All timings include ray casting and shading (without time to send image to graphics card).  1024x1024 Images.  BVH Acceleration Structure.  All surfaces set to reflective and/or refractive.

121 RT08, August ‘08 3 Performance Variables  Ray Packet Size  Scene Complexity  Ray Recursion Complexity

122 RT08, August ‘08 3 Performance Variables  Ray Packet Size  Scene Complexity  Ray Recursion Complexity 4x4 8x832x3216x16

123 RT08, August ‘08 3 Performance Variables  Ray Packet Size  Scene Complexity  Ray Recursion Complexity ERW6 (804 Triangles) Toasters (11,141 Triangles) Fairy (172,669 Triangles) Rings (217,812 Triangles)

124 RT08, August ‘08 3 Performance Variables  Ray Packet Size  Scene Complexity  Ray Recursion Complexity Primary Visibility + Point-light Shadows Primary Visibility + 2-Bounce Reflections Primary Visibility + 2-Deep Refractions

125 RT08, August ‘08 Masked Ranged Partition 0 500 1000 1500 Time (Million CPU Cycles) 4x4 8x8 16x16 32x32 Ray Packet Size Traversal vs. Ray Packet Size  Masked Traversal: performance degrades for > 4x4 packets  Ranged Traversal: performance degrades for > 8x8 packets  Paritition Traversal: performance increases with packet size Fairy Scene 2-Bounce Reflections

126 RT08, August ‘08 Masked Partition Ranged 0 400 800 1200 Time (Million CPU Cycles) Traversal vs. Recursion Complexity  Masked Traversal: Degrades with recursion complexity  Ranged Traversal: Degrades with recursion complexity  Partition Traversal: More robust to increasing recursion complexity Fairy Scene 16x16 Packets Primary Shadows Primary + 2-Deep Refractions Primary + 2-Bounce Reflections Primary + Recursion Complexity

127 RT08, August ‘08 Masked Ranged Partition 0 1000 2000 3000 Time (Million CPU Cycles) Traversal vs. Recursion Complexity  Difference between Partition and Ranged more pronounced on more complex scenes Rings Scene 16x16 Packets Primary Shadows Primary + 2-Deep Refractions Primary + 2-Bounce Reflections Primary + Recursion Complexity 4000 2x

128 RT08, August ‘08 Masked Ranged Partition 0 1000 2000 3000 Time (Million CPU Cycles) Traversal vs. Scene Complexity  Ranged Traversal: Degrades with scene complexity  Partition Traversal: More robust to increasing scene complexity 4000 2-Bounce Reflections 16x16 Packets Scene Complexity ERW6 Toasters Fairy Rings

129 RT08, August ‘08 Ranged vs. Partition Traversal  Ranged Traversal  Most ray—cell tests deep in BVH  More extra ray—triangle tests for incoherent rays  Partition Traversal  Most ray—cell tests high in BVH  No extra ray—triangle tests

130 RT08, August ‘08 Traversal: Summary  Use Ranged Traversal  Primary rays and coherent point-light shadow rays  Small to medium packets: <= 8x8 rays  Use Partition Traversal  Incoherent rays: deep reflections + refractions  Large ray packets: > =16x16 rays

131 RT08, August ‘08 With Culling No Culling 0 100 200 300 Time (Million CPU Cycles) Frustum Culling vs. Recursion Complexity  Frustum culling provides modest benefits Toasters Scene 16x16 Packets Primary Shadows Primary + 2-Deep Refractions Primary + 2-Bounce Reflections Primary + Recursion Complexity 400

132 RT08, August ‘08 Frustum Culling: Summary  Primary + Point-light Shadows  Up to 2x performance benefit possible  But more often ~1.5x or less  Reflections + Refractions  Expect 1.2x – 1.3x performance benefit

133 RT08, August ‘08 Conclusion  Use ranged and partition traversal in correct situation  16x16 packets: 3x – 6x benefit over 2x2  Whitted Ray Tracing is now interactive to real-time 11.8 FPS6.7 FPS 8.5 FPS 4 FPS

134 RT08, August ‘08 Real-Time Whitted Ray Tracing  Primary Visibility  Ranged Traversal  Point-Light  Ranged Traversal  1-Bounce Reflections  Ranged Traversal

135 RT08, August ‘08 Conclusion  Primary Visibility  Ranged Traversal  3-Bounce Reflections  Partition Traversal

136 RT08, August ‘08 Conclusion  Primary Visibility  Ranged Traversal  Point-Light Shadows  Partition Traversal  3-Deep Refractions  Partition Traversal  1-Bounce Reflections  Partition Traversal

137 RT08, August ‘08 Future Work  Study traversal algorithms and frustum culling for other global illumination algorithms:  Distributed ray tracing.  Path tracing.  Partition traversal on other hardware:  Wider SIMD.  This Session! @2:20:“Coherent Ray Tracing using Stream Filtering”, Gribble and Ramani.

138 RT08, August ‘08 Acknowledgements  Thanks to:  Lab mates at Columbia University.  Paid for by:  NSF (grants CCF 03-05322, CCF 04-46916, CCF 07- 01775), a Sloan Research Fellowship, and an ONR Young Investigator Award N00014-17-1-0900.  Intel fellowship to Ryan Overbeck and related equipment donations from Intel and NVIDIA.

139 RT08, August ‘08 Questions?


Download ppt "RT08, August ‘08 Large Ray Packets for Real-time Whitted Ray Tracing Ryan Overbeck Columbia University Ravi Ramamoorthi Columbia University William R."

Similar presentations


Ads by Google