fart/main/Material.h
Josh Holtrop c4509d0594 added an ambient color component to Material, changed Lighting to use it
git-svn-id: svn://anubis/fart/trunk@75 7f9b0f55-74a9-4bce-be96-3c2cd072584d
2009-01-31 22:34:36 +00:00

45 lines
1.0 KiB
C++

#ifndef MATERIAL_H
#define MATERIAL_H MATERIAL_H
#include "util/Color.h"
class Material
{
public:
/* static members */
static const Material white;
Material();
void setAmbientColor(const Color & ambient)
{
m_ambient_color = ambient;
}
const Color & getAmbientColor() const { return m_ambient_color; }
void setDiffuseColor(const Color & diffuse)
{
m_diffuse_color = diffuse;
}
const Color & getDiffuseColor() const { return m_diffuse_color; }
void setSpecularColor(const Color & specular)
{
m_specular_color = specular;
}
const Color & getSpecularColor() const { return m_specular_color; }
void setShininess(double shininess) { m_shininess = shininess; }
double getShininess() const { return m_shininess; }
protected:
Color m_ambient_color;
Color m_diffuse_color;
Color m_specular_color;
double m_shininess;
};
#endif