RobinTrace
plane.h
Go to the documentation of this file.
1 
2 #ifndef PLANE_H
3 #define PLANE_H
4 
5 #include "shape/shape.h"
6 
7 #include <iostream>
8 #include <cmath>
9 
11 class plane : public shape {
12  public:
14  virtual void intersect (ray &r) override;
16  virtual Vec3 normal (const ray &r) override;
17 
18  private:
19  virtual std::string print_str () const override;
20 };
21 
22 #endif //PLANE_H
Eigen::Vector3d Vec3
Definition: Vec3.h:11
Plane shape specialization.
Definition: plane.h:11
virtual void intersect(ray &r) override
Operate the intersection of ray r with the plane.
Definition: plane.cpp:7
virtual std::string print_str() const override
String for printing the object.
Definition: plane.cpp:20
virtual Vec3 normal(const ray &r) override
Compute the plane normal.
Definition: plane.cpp:15
Class for individual rays.
Definition: ray.h:9
Virtual class for shapes.
Definition: shape.h:12