|
TinyRaytracer 0.1
A simple C++ raytracer
|
Class Triangle, with 3 vertices that made it up. More...
#include <object.hpp>
Public Member Functions | |
| Triangle (Vertex a, Vertex b, Vertex c, RGB rgb) | |
| Triangle (Vertex a, Vertex b, Vertex c, std::string text) | |
| ObjectInfo | checkObject (Ray &ray) override |
| AABB | getBox () override |
| RGB | getColor (double b0, double b1, double b2) |
| void | setProperties (RGB shine, RGB tran, double ior, double roughness) override |
| virtual ObjectInfo | checkObject (Ray &ray)=0 |
| virtual void | setProperties (RGB, RGB, double, double) |
| virtual AABB | getBox ()=0 |
Public Attributes | |
| point3 | p0 |
| point3 | p1 |
| point3 | p2 |
| Three vertices of the triangle. | |
| Texcoord | tex0 |
| Texcoord | tex1 |
| Texcoord | tex2 |
| texture coordinates for the vertices,if provided. | |
| vec3 | nor |
| Normal of the triangle. | |
| point3 | e1 |
| point3 | e2 |
| The e1,e2 coordinates, precomputed for Barycentric calculation. | |
| Image | texture |
| Texture, if provided. | |
| Materials | mat |
| Material properties. | |
Public Attributes inherited from Object | |
| AABB | bbox |
| Axis-aligned bounding box for the Object class. For BVH traversal. | |
Class Triangle, with 3 vertices that made it up.
|
overridevirtual |
Implements Object.
|
inlineoverridevirtual |
Reimplemented from Object.