The normalized direction vector of the ray.
The origin point of the ray.
Tests whether this ray intersects the given AABB. Uses the slab method.
The axis-aligned bounding box.
The distance t to the intersection, or -1 if no intersection.
Tests whether this ray intersects the given bounding sphere.
The bounding sphere.
The distance t to the nearest intersection, or -1 if no intersection.
Represents a mathematical ray in 3D space.