Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

qgar::RWTree Class Reference
[Polygonal approximations]

#include <qgarlib/RWSegmentVector.H>

List of all members.


Detailed Description

Private class of class RWSegmentVector to construct a binary tree during Rosin and West's polygonal approximation.

Warning:
Class qgar::RWSegmentVector is a friend.
Todo:
Find an other solution than a private class!
Author:
Karl Tombre
Date:
July 3, 2001 00:02
Since:
Qgar 1.0

Definition at line 86 of file RWSegmentVector.H.

Private Member Functions

Constructors
 RWTree ()
 Default constructor.
 RWTree (int fi, int li, double s=0.0)
 Construct from indexes and significance.
Destructor
 ~RWTree ()
 Non-virtual destructor.
Access
double significance () const
 Get significance.
int firstIdx () const
 Get Index of first point.
int lastIdx () const
 Get Index of last point.
RWTreeleftChild () const
 Get left child.
RWTreerightChild () const
 Get right child.
Transformation
void setSignificance (double s)
 Set significance.
void setFirstIdx (int fi)
 Set index of first point.
void setLastIdx (int li)
 Set index of last point.
void setLeftChild (RWTree *ls)
 Set left child.
void setRightChild (RWTree *rs)
 Set right child.

Private Attributes

Representation of a node
int _firstIdx
 Index in chain of first point.
int _lastIdx
 Index in chain of last point.
RWTree_leftChild
 Left child.
RWTree_rightChild
 Right child.
double _significance
 Significance associated to the node.

Friends

class RWSegmentVector


Constructor & Destructor Documentation

qgar::RWTree::RWTree  )  [private]
 

Default constructor.

Definition at line 89 of file RWSegmentVector.C.

qgar::RWTree::RWTree int  fi,
int  li,
double  s = 0.0
[private]
 

Construct from indexes and significance.

Parameters:
fi index of first point
li index of last point
s significance (default 0)

Definition at line 98 of file RWSegmentVector.C.

qgar::RWTree::~RWTree  )  [private]
 

Non-virtual destructor.

Definition at line 119 of file RWSegmentVector.C.

References _leftChild, and _rightChild.


Member Function Documentation

int qgar::RWTree::firstIdx  )  const [inline, private]
 

Get Index of first point.

Definition at line 268 of file RWSegmentVector.H.

References _firstIdx.

int qgar::RWTree::lastIdx  )  const [inline, private]
 

Get Index of last point.

Definition at line 277 of file RWSegmentVector.H.

References _lastIdx.

RWTree * qgar::RWTree::leftChild  )  const [inline, private]
 

Get left child.

Definition at line 286 of file RWSegmentVector.H.

References _leftChild.

Referenced by qgar::RWSegmentVector::searchBestApproximation().

RWTree * qgar::RWTree::rightChild  )  const [inline, private]
 

Get right child.

Definition at line 295 of file RWSegmentVector.H.

References _rightChild.

Referenced by qgar::RWSegmentVector::searchBestApproximation().

void qgar::RWTree::setFirstIdx int  fi  )  [inline, private]
 

Set index of first point.

Parameters:
fi first point index

Definition at line 318 of file RWSegmentVector.H.

References _firstIdx.

void qgar::RWTree::setLastIdx int  li  )  [inline, private]
 

Set index of last point.

Parameters:
li last point index

Definition at line 327 of file RWSegmentVector.H.

References _lastIdx.

void qgar::RWTree::setLeftChild RWTree ls  )  [inline, private]
 

Set left child.

Parameters:
ls left child

Definition at line 336 of file RWSegmentVector.H.

References _leftChild.

Referenced by qgar::RWSegmentVector::searchBestApproximation().

void qgar::RWTree::setRightChild RWTree rs  )  [inline, private]
 

Set right child.

Parameters:
ls right child

Definition at line 345 of file RWSegmentVector.H.

References _rightChild.

Referenced by qgar::RWSegmentVector::searchBestApproximation().

void qgar::RWTree::setSignificance double  s  )  [inline, private]
 

Set significance.

Parameters:
s a significance

Definition at line 309 of file RWSegmentVector.H.

References _significance.

Referenced by qgar::RWSegmentVector::searchBestApproximation().

double qgar::RWTree::significance  )  const [inline, private]
 

Get significance.

Definition at line 259 of file RWSegmentVector.H.

References _significance.

Referenced by qgar::RWSegmentVector::searchBestApproximation().


Friends And Related Function Documentation

friend class RWSegmentVector [friend]
 

Definition at line 93 of file RWSegmentVector.H.


Member Data Documentation

int qgar::RWTree::_firstIdx [private]
 

Index in chain of first point.

Definition at line 107 of file RWSegmentVector.H.

Referenced by firstIdx(), and setFirstIdx().

int qgar::RWTree::_lastIdx [private]
 

Index in chain of last point.

Definition at line 112 of file RWSegmentVector.H.

Referenced by lastIdx(), and setLastIdx().

RWTree* qgar::RWTree::_leftChild [private]
 

Left child.

Definition at line 117 of file RWSegmentVector.H.

Referenced by leftChild(), setLeftChild(), and ~RWTree().

RWTree* qgar::RWTree::_rightChild [private]
 

Right child.

Definition at line 122 of file RWSegmentVector.H.

Referenced by rightChild(), setRightChild(), and ~RWTree().

double qgar::RWTree::_significance [private]
 

Significance associated to the node.

Definition at line 127 of file RWSegmentVector.H.

Referenced by setSignificance(), and significance().


The documentation for this class was generated from the following files: