geomc 1.0
A c++ linear algebra template library
|
Base class describing N-dimensional shapes which can be intersection-tested with a Ray. More...
#include <geomc/shape/Shape.h>
Public Member Functions | |
Rect< T, 1 > | intersect (const Ray< T, N > &r) const |
Ray/shape intersection. More... | |
Base class describing N-dimensional shapes which can be intersection-tested with a Ray.
Uses the curiously-recurring template pattern to perform static polymorphism.
Ray/shape intersection.
Return the possibly-empty range of ray parameters s
such that the Ray overlaps the shape at r.origin + s * r.direction
.
For non-convex objects with multiple regions of overlap, this method should return the interval containing the smallest positive value.