User Tools

Site Tools


raycasting_line_intersections

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Last revision Both sides next revision
raycasting_line_intersections [2023/04/17 15:28]
max
raycasting_line_intersections [2023/04/17 15:33]
max
Line 13: Line 13:
 Overall, raycasting is a powerful technique for simulating physics in real-time applications and games, and it has a wide range of practical uses.  Overall, raycasting is a powerful technique for simulating physics in real-time applications and games, and it has a wide range of practical uses. 
  
 +===== Raycasting functions =====
  
-===== Raycasting::Raycast(const Sphere& a, const Ray& ray) =====+==== Spheres ==== 
 + 
 +**Raycasting::Raycast(const Sphere& a, const Ray& ray)**
  
 Tests if a ray intersects a sphere. Tests if a ray intersects a sphere.
Line 27: Line 30:
   - ''float''   - The distance along the ray where the intersection occurs. If there is no intersection, returns a negative value.   - ''float''   - The distance along the ray where the intersection occurs. If there is no intersection, returns a negative value.
  
-===== Raycasting::Raycast(const AABB& aabb, const Ray& ray) =====+==== AABBs ==== 
 + 
 + 
 +**Raycasting::Raycast(const AABB& aabb, const Ray& ray)**
  
 Tests if a ray intersects an axis-aligned bounding box (AABB). Tests if a ray intersects an axis-aligned bounding box (AABB).
Line 40: Line 46:
   - ''float''   - The distance along the ray where the intersection occurs. If there is no intersection, returns a negative value.   - ''float''   - The distance along the ray where the intersection occurs. If there is no intersection, returns a negative value.
  
-===== Raycasting::Raycast(const OrientedBox& obb, const Ray& ray) =====+==== Oriented Boxes ==== 
 + 
 +**Raycasting::Raycast(const OrientedBox& obb, const Ray& ray) **
  
 Tests if a ray intersects an oriented bounding box (OBB). Tests if a ray intersects an oriented bounding box (OBB).
Line 53: Line 61:
   - ''float''   - The distance along the ray where the intersection occurs. If there is no intersection, returns a negative value.   - ''float''   - The distance along the ray where the intersection occurs. If there is no intersection, returns a negative value.
  
-===== Raycasting::Raycast(const Plane& plane, const Ray& ray) =====+==== Planes ==== 
 + 
 + 
 +**Raycasting::Raycast(const Plane& plane, const Ray& ray) **
  
 Tests if a ray intersects a plane. Tests if a ray intersects a plane.
Line 66: Line 77:
   - ''float''   - The distance along the ray where the intersection occurs. If there is no intersection, returns a negative value.   - ''float''   - The distance along the ray where the intersection occurs. If there is no intersection, returns a negative value.
  
-===== Raycasting::Raycast(const Triangle& triangle, const Ray& ray) =====+==== Triangles ==== 
 + 
 + 
 +**Raycasting::Raycast(const Triangle& triangle, const Ray& ray) **
  
 Tests if a ray intersects a triangle. Tests if a ray intersects a triangle.
Line 79: Line 93:
   - ''float''   - The distance along the ray where the intersection occurs. If there is no intersection, returns a negative value.   - ''float''   - The distance along the ray where the intersection occurs. If there is no intersection, returns a negative value.
  
-===== Raycasting::Raycast(const Mesh& mesh, const Ray& ray) =====+==== Meshes ==== 
 + 
 + 
 +**Raycasting::Raycast(const Mesh& mesh, const Ray& ray) **
  
 Tests if a ray intersects a mesh. Tests if a ray intersects a mesh.
Line 92: Line 109:
   - ''float''   - The distance along the ray where the intersection occurs. If there is no intersection, returns a negative value.   - ''float''   - The distance along the ray where the intersection occurs. If there is no intersection, returns a negative value.
  
-===== Raycasting::Raycast(const Entity& entity, const Ray& ray) =====+==== Entities ==== 
 + 
 +**Raycasting::Raycast(const Entity& entity, const Ray& ray) **
  
 Tests if a ray intersects an entity. Tests if a ray intersects an entity.
Line 104: Line 123:
  
   - ''float''   - The distance along the ray where the intersection occurs. If there is no intersection, returns a negative value.   - ''float''   - The distance along the ray where the intersection occurs. If there is no intersection, returns a negative value.
 +
 +===== Line testing ===== 
  
 ===== Raycasting::Linetest(const Sphere& sphere, const Line& line) ===== ===== Raycasting::Linetest(const Sphere& sphere, const Line& line) =====
raycasting_line_intersections.txt · Last modified: 2023/04/17 16:13 by max