GAMES101 14 Ray Tracing 2 Accelerate
14 Ray Tracing 2 AccelerateAcceleration: Bounding Volumes
Ray-Intersection With a Box
Understanding : box is the intersection of 3 pairs of slabs.
Axis-Aligned Bounding Box: AABB 轴对齐包围盒
光线进入所有包围面,进入盒子。出去其中一个包围面,出去包围盒。
$t_{enter}=max{t_{min}}, t_{exit}=min{t_{max}}$
If $t_{enter}<t_{exit}$, ray stay a while in the box.
$t_{enter}<t_{exit} and t_{exit}>=0$, ray and AABB intersection.
Grid Solution: 在bounding box 里面再弄一堆格子
Spatial Partitioning Examples
Oct-Tree
KD-Tree
BSP- ...