src/rcrt/bxdf/Phong.h

Go to the documentation of this file.
00001 #ifndef PHONG_H_
00002 #define PHONG_H_
00003 
00004 #include "BXDF.h"
00005 
00006 namespace rcrt
00007 {
00008 
00014 class Phong : public rcrt::BXDF
00015 {
00016 private:
00017         // diffuse part : kd = Kd/pi <- in BXDF
00018         // specular part : ks = Ks * (n+2)/(2pi)  <- in BXDF
00019         float n;    // shininess exponent
00020         
00021 public:
00022         Phong(const RGBColor& Kd, const RGBColor& Ks, const float& e);
00023         virtual ~Phong();
00024         
00025         virtual RGBColor eval(const Vec3D& wOut, const Vec3D& wInc, const Vec3D& normal) const;
00026         virtual RGBColor evalDiffuse(const Vec3D& wOut, const Vec3D& wInc, const Vec3D& normal) const;
00027         virtual RGBColor evalSpecular(const Vec3D& wOut, const Vec3D& wInc, const Vec3D& normal) const;
00028         float pdf(const Vec3D& wOut, const Vec3D& wInc, const Vec3D& normal) const;
00029         
00030         virtual bool specular() const;
00031         virtual bool glossy() const;
00032         virtual bool diffuse() const;
00033         virtual bool fresnel() const;
00034 };
00035 
00036 }
00037 
00038 #endif /*PHONG_H_*/

Generated on Thu Jan 31 19:26:19 2008 for RenderingCompetitionRayTracer by  doxygen 1.5.3