23 lines
333 B
C++
23 lines
333 B
C++
#pragma once
|
|
#ifndef FIGURE_HPP
|
|
#define FIGURE_HPP
|
|
|
|
#include <glm/vec3.hpp>
|
|
|
|
#include "ray.hpp"
|
|
#include "material.hpp"
|
|
|
|
using glm::vec3;
|
|
|
|
class Figure {
|
|
public:
|
|
Material m_mat;
|
|
|
|
virtual ~Figure() { }
|
|
|
|
virtual bool intersect(Ray & r, float & t) const = 0;
|
|
virtual vec3 normal_at_int(Ray & r, float & t) const = 0;
|
|
};
|
|
|
|
#endif
|