added util/Color module, updated Light and PointLight

git-svn-id: svn://anubis/fart/trunk@49 7f9b0f55-74a9-4bce-be96-3c2cd072584d
This commit is contained in:
Josh Holtrop committed 2009-01-26 20:08:42 +00:00
1 parent 072bf75c04
commit e0d545a6b7
6 files changed
+76 -7

No files matched your search

+1 -1
View File
@@ -2,7 +2,7 @@
#include "Light.h"
#include "util/Vector.h"
Light::Light(const Vector & position)
Light::Light(const Vector & position, const Color & color)
{
m_position = position;
}
+3 -2
View File
@@ -3,14 +3,15 @@
#define LIGHT_H LIGHT_H
#include "util/Vector.h"
#include "util/Color.h"
class Light
{
public:
Light(const Vector & position);
Light(const Vector & position, const Color & color = Color::white);
const Vector & getPosition() const { return m_position; }
private:
protected:
Vector m_position;
};
+2 -2
View File
@@ -1,7 +1,7 @@
#include "PointLight.h"
PointLight::PointLight(const Vector & position)
: Light(position)
PointLight::PointLight(const Vector & position, const Color & color)
: Light(position, color)
{
}
+3 -2
View File
@@ -3,13 +3,14 @@
#define POINTLIGHT_H POINTLIGHT_H
#include "Light.h"
#include "util/Color.h"
class PointLight : public Light
{
public:
PointLight(const Vector & position);
PointLight(const Vector & position, const Color & color = Color::white);
private:
protected:
};
#endif