rcrt::PhotonKDTree Class Reference

#include <PhotonKDTree.h>

Collaboration diagram for rcrt::PhotonKDTree:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 PhotonKDTree (const float &maxSqrRadius)
virtual ~PhotonKDTree ()
void buildTree (std::vector< Photon * > *phots)
void getKNearest (std::vector< PKDSearchP > *result, const unsigned int &k, const Point3D &pos, const Vec3D &normal, const float &radiusSqr, const float &flat) const

Static Private Member Functions

static bool splitPlaneCompare (PKDSplitPlane *a, PKDSplitPlane *b)

Private Attributes

std::vector< Photon * > * photons
float maxSqrRadius
PKDNoderoot
bool empty


Detailed Description

Definition at line 10 of file PhotonKDTree.h.


Constructor & Destructor Documentation

rcrt::PhotonKDTree::PhotonKDTree ( const float &  maxSqrRadius  ) 

Definition at line 11 of file PhotonKDTree.cpp.

rcrt::PhotonKDTree::~PhotonKDTree (  )  [virtual]

Definition at line 16 of file PhotonKDTree.cpp.

References root.


Member Function Documentation

bool rcrt::PhotonKDTree::splitPlaneCompare ( PKDSplitPlane a,
PKDSplitPlane b 
) [static, private]

Definition at line 21 of file PhotonKDTree.cpp.

References rcrt::PKDSplitPlane::axis, rcrt::Photon::getPos(), and rcrt::PKDSplitPlane::p.

Referenced by buildTree().

void rcrt::PhotonKDTree::buildTree ( std::vector< Photon * > *  phots  ) 

Definition at line 26 of file PhotonKDTree.cpp.

References empty, maxSqrRadius, photons, root, splitPlaneCompare(), X_AXIS, Y_AXIS, and Z_AXIS.

Referenced by rcrt::PhotonMap::generate().

void rcrt::PhotonKDTree::getKNearest ( std::vector< PKDSearchP > *  result,
const unsigned int &  k,
const Point3D pos,
const Vec3D normal,
const float &  radiusSqr,
const float &  flat 
) const

Definition at line 73 of file PhotonKDTree.cpp.

References empty, rcrt::PKDNode::getKNearest(), and root.

Referenced by rcrt::PhotonMap::getRadiance().


Member Data Documentation

std::vector<Photon*>* rcrt::PhotonKDTree::photons [private]

Definition at line 13 of file PhotonKDTree.h.

Referenced by buildTree().

float rcrt::PhotonKDTree::maxSqrRadius [private]

Definition at line 14 of file PhotonKDTree.h.

Referenced by buildTree().

PKDNode* rcrt::PhotonKDTree::root [private]

Definition at line 15 of file PhotonKDTree.h.

Referenced by buildTree(), getKNearest(), and ~PhotonKDTree().

bool rcrt::PhotonKDTree::empty [private]

Definition at line 16 of file PhotonKDTree.h.

Referenced by buildTree(), and getKNearest().


The documentation for this class was generated from the following files:
Generated on Thu Jan 31 19:32:23 2008 for RenderingCompetitionRayTracer by  doxygen 1.5.3