March 2017
Intermediate to advanced
480 pages
11h 3m
English
To Raycast against a plane we must find a point which is on the plane being cast against and also along the normal of the ray. We know a point is on the surface of a plane if it satisfies the plane equation. If no point along the ray satisfies the plane equation, the ray and plane do not intersect:

We are going to implement a function that performs a Raycast against a plane. This function will return t, the time along the ray at which it intersects the plane. If there is no intersection, the value of t will be negative.
Follow these steps to implement raycasting against a plane:
Raycast function in ...Read now
Unlock full access