3 #include "core/almost_equal.h" 4 #include "core/cl/scene_structs.h" 11 struct alignas(1 << 4)
ray final {
18 static constexpr
auto value = R
"( 26 constexpr auto to_tuple(
const ray& x) {
27 return std::tie(x.position, x.direction);
30 constexpr
bool operator==(
const ray& a,
const ray& b) {
31 return to_tuple(a) == to_tuple(b);
34 constexpr
bool operator!=(
const ray& a,
const ray& b) {
return !(a == b); }
46 static constexpr
auto value = R
"( 56 return std::tie(a.t, a.u, a.v) == std::tie(b.t, b.u, b.v);
65 return almost_equal(i.u, 0.0f, ulp) || almost_equal(i.v, 0.0f, ulp) ||
66 almost_equal(i.u + i.v, 1.0f, ulp);
78 static constexpr
auto value = R
"( 87 return std::tie(x.inter, x.index);
91 return to_tuple(a) == to_tuple(b);
Definition: geometry_structs.h:11
Definition: representation.h:7
Definition: geometry_structs.h:71
Definition: geometry_structs.h:38
Definition: capsule_base.h:9