ObjectInfo is a class that passes the parameters of a ray hit, and the details of the object that was...
Definition: object.hpp:50
Definition: struct.hpp:39
Definition: struct.hpp:20
Class Ray, consists of a eye and direction.
Definition: struct.hpp:68
RGBA getColorBulb(double lambert, RGB objColor, RGB lightColor, double t)
Get the Color of Bulb (scene light)
Definition: draw.cpp:366
RGBA shootPrimaryRay(double x, double y)
Shoots a primary ray into the scene, at pixel location (x,y).
Definition: draw.cpp:69
RGBA globalIllumination(const ObjectInfo &obj, int gi_bounce)
Get the global illumination light color.
Definition: draw.cpp:279
void render(Image &img)
The render function that loops over the screen of pixels.
Definition: draw.cpp:28
RGBA getColorSun(double lambert, RGB objColor, RGB lightColor)
Get the Color of Sun (directional light)
Definition: draw.cpp:347
RGBA reflectionLight(const Ray &ray, const ObjectInfo &obj)
Get the reflection light color.
Definition: draw.cpp:163
ObjectInfo hitNearest(Ray &ray)
Gets the nearest object in the path of the ray.
Definition: draw.cpp:98
ObjectInfo hitMiss()
Does nothing.
Definition: draw.cpp:110
ObjectInfo checkPlane(Ray &ray, bool exit_early=false)
Check if any planes are intersecting with the ray.
Definition: draw.cpp:314
RGBA diffuseLight(const ObjectInfo &obj)
Get the diffuse light color,with shadow checking.
Definition: draw.cpp:123
RGBA refractionLight(const Ray &ray, const ObjectInfo &obj)
Get the refraction light color.
Definition: draw.cpp:217