2#include "resources/Mesh.hpp"
19 Ray(
const glm::vec3 & origin,
const glm::vec3 & direction);
40 static bool sphere(
const glm::vec3 & rayOrigin,
const glm::vec3 & rayDir,
float radius, glm::vec2 & roots);
Represent the smallest axis-aligne box containing a given object or region of space.
Definition: Bounds.hpp:28
Provide helpers for basic analytic intersections.
Definition: Intersection.hpp:27
static bool sphere(const glm::vec3 &rayOrigin, const glm::vec3 &rayDir, float radius, glm::vec2 &roots)
Definition: Intersection.cpp:7
static bool box(const Ray &ray, const BoundingBox &box, float mini, float maxi)
Definition: Intersection.cpp:22
Represent a ray, shot from a given position in a specific direction.
Definition: Intersection.hpp:10
const glm::vec3 invdir
Ray reciprocal direction (normalized).
Definition: Intersection.hpp:13
const glm::vec3 pos
Ray position.
Definition: Intersection.hpp:11
const glm::vec3 dir
Ray direction (normalized).
Definition: Intersection.hpp:12