Ray Tracer  2020
DirectionalLightSource.h
Go to the documentation of this file.
1 
2 #pragma once
3 
4 #ifndef DIRECTIONAL_LIGHT_SOURCE_H_INCLUDED
5 #define DIRECTIONAL_LIGHT_SOURCE_H_INCLUDED
6 
7 #include "LightSource.h"
8 
22 
23 public:
24 
32  DirectionalLightSource(const Colour& colour, const Direction& direction);
33 
39 
42 
49 
57  Colour getIlluminationAt(const Point& point) const;
58 
67  double getDistanceToLight(const Point& point) const;
68 
69 
78  Direction getLightDirection(const Point& point) const;
79 
80 private:
81 
83 
84 };
85 #endif
LightSource class header file.
Class to store colour information.
Definition: Colour.h:25
Class for Direction Vectors.
Definition: Direction.h:22
Light emitted from afar in a particular Direction.
Definition: DirectionalLightSource.h:21
Direction direction_
The Direction that this light source sheds light in.
Definition: DirectionalLightSource.h:82
Direction getLightDirection(const Point &point) const
Direction from light source to a point.
Definition: DirectionalLightSource.cpp:34
DirectionalLightSource(const Colour &colour, const Direction &direction)
DirectionalLightSource constructor.
Definition: DirectionalLightSource.cpp:4
~DirectionalLightSource()
DirectionalLightSource destructor.
Definition: DirectionalLightSource.cpp:14
double getDistanceToLight(const Point &point) const
Determine how far away the light source is from a given Point.
Definition: DirectionalLightSource.cpp:30
Colour getIlluminationAt(const Point &point) const
Determine how much light reaches a Point from this DirectionalLightSource.
Definition: DirectionalLightSource.cpp:26
DirectionalLightSource & operator=(const DirectionalLightSource &lightSource)
DirectionalLightSource assignment operator.
Definition: DirectionalLightSource.cpp:18
Abstract base class for LightSources.
Definition: LightSource.h:23
Class for Point Vectors.
Definition: Point.h:22