diff options
| author | ladevieq <ladevie.quentin@gmail.com> | 2020-12-21 13:51:18 +0100 |
|---|---|---|
| committer | ladevieq <ladevie.quentin@gmail.com> | 2020-12-21 13:51:18 +0100 |
| commit | 56bed8e38f5b6d9effd77371ad781ae71601205b (patch) | |
| tree | 1f57155b8f5b15fd2b33ac7e926e3e5d0ce1754c /include/metal.hpp | |
| parent | 92d66138f53645f3400f633c9821a6fa36f589e0 (diff) | |
Add lambertian and metallic materials
Diffstat (limited to 'include/metal.hpp')
| -rw-r--r-- | include/metal.hpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/include/metal.hpp b/include/metal.hpp new file mode 100644 index 0000000..5516890 --- /dev/null +++ b/include/metal.hpp @@ -0,0 +1,16 @@ +#ifndef __METAL_HPP_ +#define __METAL_HPP_ + +#include "material.hpp" + +class metal : public material { + public: + metal(const color& albedo, double f); + + virtual bool scatter(const ray& r, const struct hit_info& info, color& attenuation, ray& scattered) const; + + color albedo; + double fuzz; +}; + +#endif // !__METAL_HPP_ |
