Raytracer
Loading...
Searching...
No Matches
Metal.hpp
1#include "interfaces/IMaterial.hpp"
2
3#ifndef __METAL_HPP__
4 #define __METAL_HPP__
5
6namespace Raytracer::Materials
7{
8 class Metal : public Interfaces::IMaterial {
9 private:
10 Utils::Color _albedo;
11 double _fuzz;
12
13 public:
14 Metal(const Utils::Color &albedo, double fuzz);
15 bool scatter(const Core::Ray &ray, const Core::Payload &payload,
16 Utils::Color &attenuation, Core::Ray &scattered) const override;
18 double u, double v, const Utils::Point3 &point) const override;
19 };
20} // namespace Raytracer::Materials
21
22#endif /* __METAL_HPP__ */
Definition Payload.hpp:11
Definition Ray.hpp:9
Definition IMaterial.hpp:14
Definition Metal.hpp:8
bool scatter(const Core::Ray &ray, const Core::Payload &payload, Utils::Color &attenuation, Core::Ray &scattered) const override
Scatter the ray with the Metal material.
Definition Metal.cpp:34
Metal(const Utils::Color &albedo, double fuzz)
Construct a new Metal object.
Definition Metal.cpp:15
Utils::Color emitted(double u, double v, const Utils::Point3 &point) const override
Emitted light of the Metal material.
Definition Metal.cpp:59
Definition VecN.hpp:40