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

qgar::LinkedChainList Class Reference
[Points]

#include <qgarlib/LinkedChainList.H>

List of all members.


Detailed Description

List of linked chains of integer points.

Todo:
This class should not derive from STL class list, but should be its client! The current implementation may be/is the cause of memory losses due to the use of dynamically allocated objects by the function members...
Author:
Karl Tombre
Date:
July 3, 2001 16:14
Since:
Qgar 1.0

Definition at line 80 of file LinkedChainList.H.

Public Member Functions

Constructors
 LinkedChainList (const BinaryImage &img, unsigned int minChainLength=3, unsigned int minCycleLength=4)
 Build from given binary image.
 LinkedChainList (const LabeledSkeletonImage &skel) throw (QgarErrorDeveloper)
 Build from a labeled skeleton.
 LinkedChainList (unsigned int minChainLength=0, unsigned int minCycleLength=0)
 Build with given minimal length parameters.
Destructor
virtual ~LinkedChainList ()
 Virtual destructor.

Private Member Functions

Auxiliary functions
PointChainaChain (PointChain *ch, int l, int c, GreyLevelImage &wkImg)
 Recursive function for chaining.

Private Attributes

Auxiliary data
int _minChainLength
 Minimum length of a valid chain.
int _minCycleLength
 Minimum length of a valid cycle.


Constructor & Destructor Documentation

qgar::LinkedChainList::LinkedChainList const BinaryImage img,
unsigned int  minChainLength = 3,
unsigned int  minCycleLength = 4
 

Build from given binary image.

Build chains of points from a binary image, using an algorithm designed by Salvatore Tabbone, and slightly improved by Karl Tombre.

  • Chains of length smaller than threshold minChainlength are removed.
  • Cycles of length smaller than threshold minCycleLength are not taken into account.

Definition at line 697 of file LinkedChainList.C.

References _minChainLength, aChain(), qgar::GenImage< T, CheckPolicy >::height(), qgar::LINKEDCHAINLIST_canMerge(), qgar::LINKEDCHAINLIST_connect4(), qgar::LINKEDCHAINLIST_connect8(), qgar::LINKEDCHAINLIST_mergeChains(), qgar::LINKEDCHAINLIST_MINL, qgar::LINKEDCHAINLIST_neigh(), qgar::GenImage< T, CheckPolicy >::pPixMap(), qgar::GenPointChain< T >::size(), qgar::GenImage< T, CheckPolicy >::width(), qgar::GenPoint< T >::x(), and qgar::GenPoint< T >::y().

qgar::LinkedChainList::LinkedChainList const LabeledSkeletonImage skel  )  throw (QgarErrorDeveloper)
 

Build from a labeled skeleton.

This function builds chains of points from a labeled skeleton image. The algorithm used here takes advantage of the properties of a labeled skeleton to construct chains taking junctions into account.

Exceptions:
qgar::QgarErrorDeveloper (strange things happen!)

Definition at line 833 of file LinkedChainList.C.

References qgar::LINKEDCHAINLIST_crossNb(), qgar::LINKEDCHAINLIST_degree(), qgar::LINKEDCHAINLIST_loadBinNeigh(), qgar::LINKEDCHAINLIST_MARK, qgar::LINKEDCHAINLIST_neigh4(), qgar::LINKEDCHAINLIST_neigh4M(), qgar::LINKEDCHAINLIST_neigh8(), qgar::LINKEDCHAINLIST_neigh8M(), qgar::LINKEDCHAINLIST_neighPlus(), qgar::GenImage< T, CheckPolicy >::pPixMap(), qgar::GenPointChain< T >::push_back(), qgar::GenPoint< T >::translate(), qgar::GenPoint< T >::x(), and qgar::GenPoint< T >::y().

qgar::LinkedChainList::LinkedChainList unsigned int  minChainLength = 0,
unsigned int  minCycleLength = 0
 

Build with given minimal length parameters.

For temporary use...

Todo:
  • Karl's note: For temporary use.
  • G!'s note: Make it actually temporary!

Definition at line 1125 of file LinkedChainList.C.

qgar::LinkedChainList::~LinkedChainList  )  [virtual]
 

Virtual destructor.

Definition at line 1144 of file LinkedChainList.C.


Member Function Documentation

PointChain * qgar::LinkedChainList::aChain PointChain ch,
int  l,
int  c,
GreyLevelImage wkImg
[private]
 

Recursive function for chaining.

Definition at line 1160 of file LinkedChainList.C.

References _minChainLength, _minCycleLength, qgar::LINKEDCHAINLIST_canMerge(), qgar::LINKEDCHAINLIST_connect4(), qgar::LINKEDCHAINLIST_connect4M(), qgar::LINKEDCHAINLIST_connect8(), qgar::LINKEDCHAINLIST_connect8M(), qgar::LINKEDCHAINLIST_markNeigh(), qgar::LINKEDCHAINLIST_mergeChains(), qgar::LINKEDCHAINLIST_neigh(), qgar::LINKEDCHAINLIST_neigh4M(), qgar::LINKEDCHAINLIST_neigh8M(), qgar::LINKEDCHAINLIST_neighM(), qgar::LINKEDCHAINLIST_tooSmall(), qgar::GenImage< T, CheckPolicy >::pPixMap(), qgar::GenPointChain< T >::push_back(), qgar::GenPointChain< T >::size(), qgar::GenImage< T, CheckPolicy >::width(), qgar::GenPoint< T >::x(), and qgar::GenPoint< T >::y().

Referenced by LinkedChainList().


Member Data Documentation

int qgar::LinkedChainList::_minChainLength [private]
 

Minimum length of a valid chain.

Definition at line 160 of file LinkedChainList.H.

Referenced by aChain(), and LinkedChainList().

int qgar::LinkedChainList::_minCycleLength [private]
 

Minimum length of a valid cycle.

Definition at line 165 of file LinkedChainList.H.

Referenced by aChain().


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