#include <RGBColor.h>
Public Member Functions | |
RGBColor (float c=0) | |
RGBColor (float r, float g, float b) | |
RGBColor (const RGBColor &col) | |
virtual | ~RGBColor () |
const RGBColor & | operator= (const RGBColor &col) |
RGBColor | operator+ (const RGBColor &col) const |
RGBColor | operator- (const RGBColor &col) const |
RGBColor | operator * (float f) const |
RGBColor | operator * (const RGBColor &col) const |
RGBColor | operator/ (float f) const |
bool | operator== (const RGBColor &col) const |
float | r () const |
float | g () const |
float | b () const |
float | avg () const |
float | sum () const |
RGBColor | clamped () const |
const float & | max () const |
Static Public Attributes | |
static const RGBColor | BLACK = RGBColor(0) |
static const RGBColor | WHITE = RGBColor(1) |
static const RGBColor | RED = RGBColor(1,0,0) |
static const RGBColor | GREEN = RGBColor(0,1,0) |
static const RGBColor | BLUE = RGBColor(0,0,1) |
Private Member Functions | |
void | assign (const RGBColor &col) |
Private Attributes | |
float | values [3] |
Definition at line 9 of file RGBColor.h.
rcrt::RGBColor::RGBColor | ( | float | c = 0 |
) |
Definition at line 7 of file RGBColor.cpp.
References values.
Referenced by clamped(), operator *(), operator+(), operator-(), and operator/().
rcrt::RGBColor::RGBColor | ( | float | r, | |
float | g, | |||
float | b | |||
) |
rcrt::RGBColor::RGBColor | ( | const RGBColor & | col | ) |
rcrt::RGBColor::~RGBColor | ( | ) | [virtual] |
Definition at line 24 of file RGBColor.cpp.
void rcrt::RGBColor::assign | ( | const RGBColor & | col | ) | [private] |
Definition at line 28 of file RGBColor.cpp.
References values.
Referenced by operator=(), and RGBColor().
RGBColor rcrt::RGBColor::operator * | ( | float | f | ) | const |
RGBColor rcrt::RGBColor::operator/ | ( | float | f | ) | const |
bool rcrt::RGBColor::operator== | ( | const RGBColor & | col | ) | const |
float rcrt::RGBColor::r | ( | ) | const |
Definition at line 78 of file RGBColor.cpp.
References values.
Referenced by rcrt::operator-(), rcrt::operator<<(), rcrt::RGBAColor::RGBAColor(), rcrt::AreaLightSampler::sample(), rcrt::BSDFMaterial::scatterPhoton(), rcrt::TracingStrategy::trace(), and rcrt::RayCaster::trace().
float rcrt::RGBColor::g | ( | ) | const |
Definition at line 83 of file RGBColor.cpp.
References values.
Referenced by rcrt::operator-(), operator/(), rcrt::operator<<(), rcrt::RGBAColor::RGBAColor(), rcrt::AreaLightSampler::sample(), rcrt::TracingStrategy::trace(), and rcrt::RayCaster::trace().
float rcrt::RGBColor::b | ( | ) | const |
Definition at line 88 of file RGBColor.cpp.
References values.
Referenced by rcrt::operator-(), rcrt::operator<<(), rcrt::RGBAColor::RGBAColor(), rcrt::AreaLightSampler::sample(), rcrt::TracingStrategy::trace(), and rcrt::RayCaster::trace().
float rcrt::RGBColor::avg | ( | ) | const |
Definition at line 93 of file RGBColor.cpp.
References values.
Referenced by rcrt::SimpleTracer::trace(), and rcrt::PhotonTracer::trace().
float rcrt::RGBColor::sum | ( | ) | const |
Definition at line 98 of file RGBColor.cpp.
References values.
Referenced by rcrt::PhotonMap::generateJob().
RGBColor rcrt::RGBColor::clamped | ( | ) | const |
Definition at line 103 of file RGBColor.cpp.
References RGBColor(), and values.
Referenced by rcrt::PhotonTracer::trace().
const float & rcrt::RGBColor::max | ( | ) | const |
float rcrt::RGBColor::values[3] [private] |
Definition at line 12 of file RGBColor.h.
Referenced by assign(), avg(), b(), clamped(), g(), max(), operator *(), operator+(), operator-(), operator/(), operator==(), r(), RGBColor(), and sum().
const RGBColor rcrt::RGBColor::BLACK = RGBColor(0) [static] |
Definition at line 38 of file RGBColor.h.
Referenced by rcrt::ImageMaterial::getEmitted(), rcrt::LSTreeLeaf::getVariance(), rcrt::StereoMetaTracer::trace(), rcrt::SimpleTracer::trace(), rcrt::RayCaster::trace(), rcrt::PhotonTracer::trace(), rcrt::DebugTracer::trace(), and rcrt::BIHTracer::trace().
const RGBColor rcrt::RGBColor::WHITE = RGBColor(1) [static] |
const RGBColor rcrt::RGBColor::RED = RGBColor(1,0,0) [static] |
Definition at line 40 of file RGBColor.h.
const RGBColor rcrt::RGBColor::GREEN = RGBColor(0,1,0) [static] |
Definition at line 41 of file RGBColor.h.
const RGBColor rcrt::RGBColor::BLUE = RGBColor(0,0,1) [static] |
Definition at line 42 of file RGBColor.h.