|
RobinTrace
|
Plane shape specialization. More...
#include <plane.h>
Public Member Functions | |
| virtual void | intersect (ray &r) override |
Operate the intersection of ray r with the plane. More... | |
| virtual Vec3 | normal (const ray &r) override |
| Compute the plane normal. More... | |
Private Member Functions | |
| virtual std::string | print_str () const override |
| String for printing the object. | |
Plane shape specialization.
|
overridevirtual |
Operate the intersection of ray r with the plane.
The ray is assumed to rest at the current LCS plane, so intersect does nothing for a plane shape.
There are no error cases.
Implements shape.
Compute the plane normal.
The plane shape normal is position-invariant. Its value is always
\[ \overrightarrow{N} = (0, 0, -\textrm{sign}(n))\]
There are no error cases.
Implements shape.