Code clean up and refactoring.

This commit is contained in:
2016-12-26 15:41:29 -04:00
parent 876ecc14cc
commit 2d437f07bc
10 changed files with 183 additions and 85 deletions

View File

@@ -6,13 +6,15 @@
#include "ray.hpp"
using glm::vec3;
class Figure {
public:
vec3 color;
virtual ~Figure() { }
virtual bool intersect(Ray & r, float & t) const = 0;
virtual bool intersect(Ray & r, float & t, vec3 & n) const = 0;
virtual void set_color(float r, float g, float b) {
color = vec3(r, g, b);