Raytracer
Loading...
Searching...
No Matches
Public Member Functions | List of all members
Raytracer::Core::Payload Class Reference

Public Member Functions

void setFaceNormal (const Core::Ray &ray, const Utils::Vec3 &outwardNormal)
 Set the face normal based on the ray and the outward normal.
 

Member Function Documentation

◆ setFaceNormal()

void Raytracer::Core::Payload::setFaceNormal ( const Core::Ray & ray,
const Utils::Vec3 & outwardNormal )

Set the face normal based on the ray and the outward normal.

This function sets the face normal based on the ray and the outward normal. If the ray is outside the object, the face normal is the outward normal. If the ray is inside the object, the face normal is the negative of the outward normal.

Parameters
rayThe ray to set the face normal from.
outwardNormalThe outward normal to set the face normal from.
Returns
void

The documentation for this class was generated from the following files: