6#include <Common/assertion.h>
7#include <Common/primitive_type.h>
14template<
typename Index = u
int32>
25 struct IndexedIntersectables
27 std::vector<const Intersectable*> vec;
29 const Intersectable* operator () (
const std::size_t index)
const
31 PH_ASSERT_LT(index, vec.size());
37 struct IntersectableAABBCalculator
41 PH_ASSERT(intersectable);
48 IndexedIntersectables,
49 IntersectableAABBCalculator,
Lightweight ray intersection testing and reporting object. If an intersection is found,...
Definition HitProbe.h:27
An object in the scene that a ray can intersect with.
Definition Intersectable.h:31
virtual math::AABB3D calcAABB() const =0
Calculates Axis-Aligned Bounding Box (AABB) of itself.
Definition Intersector.h:14
Represents a ray in space.
Definition Ray.h:21
Definition TIndexedKdtreeIntersector.h:16
TIndexedKdtreeIntersector(math::IndexedKdtreeParams params=math::IndexedKdtreeParams())
Definition TIndexedKdtreeIntersector.ipp:14
void update(TSpanView< const Intersectable * > intersectables) override
Definition TIndexedKdtreeIntersector.ipp:28
bool isIntersecting(const Ray &ray, HitProbe &probe) const override
Determine whether a given ray hits the object.
Definition TIndexedKdtreeIntersector.ipp:46
math::AABB3D calcAABB() const override
Calculates Axis-Aligned Bounding Box (AABB) of itself.
Definition TIndexedKdtreeIntersector.ipp:75
Definition IndexedKdtreeParams.h:9
Definition TIndexedKdtree.h:28
The root for all renderer implementations.
Definition EEngineProject.h:6
std::span< const T, EXTENT > TSpanView
Same as TSpan, except that the objects are const-qualified. Note that for pointer types,...
Definition TSpan.h:19