Files
PhotonMF/light.hpp

27 lines
494 B
C++
Raw Normal View History

2016-12-26 15:41:29 -04:00
#pragma once
#ifndef LIGHT_HPP
#define LIGHT_HPP
#include <glm/vec3.hpp>
#include "ray.hpp"
#include "material.hpp"
2016-12-26 19:14:21 -04:00
using glm::vec3;
2016-12-26 15:41:29 -04:00
class Light {
public:
2016-12-26 19:14:21 -04:00
vec3 m_position;
vec3 m_diffuse;
vec3 m_specular;
2016-12-26 15:41:29 -04:00
virtual ~Light() { }
2017-01-02 04:23:48 -04:00
virtual vec3 direction(vec3 point) = 0;
virtual float distance(vec3 point) = 0;
2017-01-05 06:16:14 -04:00
virtual vec3 diffuse(vec3 normal, Ray & r, float t, Material & m) const = 0;
virtual vec3 specular(vec3 normal, Ray & r, float t, Material & m) const = 0;
2016-12-26 15:41:29 -04:00
};
#endif