#include <polygon.h>
Inheritance diagram for Polygon:
Public Member Functions | |
Polygon () | |
Polygon (Material, int) | |
Polygon (Material mat) | |
virtual Point | objectCentre (void) |
void | setMaxPoints (int m) |
int | numPoints () |
Point | point (int i) |
void | set (Point p) |
void | planeEquation (void) |
void | planeEquation (Vector &normal, float &d) |
float | evalPlaneEquation (Point) |
float | evalPlaneEquation (Vector v) |
Vector | normal (Point) |
bool | intersect (Ray ray, float &t, Colour &colour) |
float | TriangularSampling (Point &p, float s, float t, int Type) |
float | RectangularSampling (Point &p, float s, float t, int Type) |
float | PolygonSampling (Point &p, float s, float t, int Type) |
bool | sample (Point &p, float &pdf, const Point &f, float s, float t) |
void | print (ostream &) |
void | read (istream &) |
virtual eObjectType | objectType (void) const |
Private Attributes | |
int | Max |
int | N |
Point * | P |
Vector | Nm |
float | D |
Friends | |
ostream & | operator<< (ostream &, Polygon) |
istream & | operator>> (istream &, Polygon &) |
Polygon::Polygon | ( | ) | [inline] |
Polygon::Polygon | ( | Material | , | |
int | ||||
) |
Polygon::Polygon | ( | Material | mat | ) | [inline] |
void Polygon::setMaxPoints | ( | int | m | ) | [inline] |
int Polygon::numPoints | ( | ) | [inline] |
Point Polygon::point | ( | int | i | ) | [inline] |
void Polygon::set | ( | Point | p | ) |
void Polygon::planeEquation | ( | void | ) |
void Polygon::planeEquation | ( | Vector & | normal, | |
float & | d | |||
) |
float Polygon::evalPlaneEquation | ( | Point | ) |
float Polygon::evalPlaneEquation | ( | Vector | v | ) |
float Polygon::TriangularSampling | ( | Point & | p, | |
float | s, | |||
float | t, | |||
int | Type | |||
) |
float Polygon::RectangularSampling | ( | Point & | p, | |
float | s, | |||
float | t, | |||
int | Type | |||
) |
float Polygon::PolygonSampling | ( | Point & | p, | |
float | s, | |||
float | t, | |||
int | Type | |||
) |
Implements GObject.
void Polygon::print | ( | ostream & | ) | [virtual] |
Implements GObject.
void Polygon::read | ( | istream & | ) | [virtual] |
Implements GObject.
virtual eObjectType Polygon::objectType | ( | void | ) | const [inline, virtual] |
Implements GObject.
ostream& operator<< | ( | ostream & | s, | |
Polygon | poly | |||
) | [friend] |
istream& operator>> | ( | istream & | s, | |
Polygon & | poly | |||
) | [friend] |
int Polygon::Max [private] |
int Polygon::N [private] |
Point* Polygon::P [private] |
Vector Polygon::Nm [private] |
float Polygon::D [private] |