Add renderstat to get some info about rendering.

This commit is contained in:
Godzil
2020-02-27 17:20:55 +00:00
parent a4ddfddbf3
commit a6f0422bd1
19 changed files with 194 additions and 12 deletions

View File

@@ -11,6 +11,7 @@
#include <tuple.h>
#include <colour.h>
#include <renderstat.h>
enum LightType
{
@@ -26,7 +27,8 @@ public:
public:
Light(LightType type = POINT_LIGHT, Tuple position=Point(0, 0, 0),
Colour intensity=Colour(1, 1, 1)) : type(type), position(position), intensity(intensity) { };
Colour intensity=Colour(1, 1, 1)) : type(type), position(position), intensity(intensity)
{ stats.addLight(); };
bool operator==(const Light &b) const { return this->intensity == b.intensity &&
this->position == b.position &&