LTI-Lib latest version v1.9 - last update 10 Apr 2010

lti::camshiftTracker Class Reference

This is the implementation of the CAMSHIFT (Continuously Adaptive Mean Shift) Tracking algorithm as described in: G.Bradski, "Computer Vision Face Tracking For Use in a Perceptual User Interface", IEEE Workshop on Applic.Comp.Vis.,1998. More...

#include <ltiCamshiftTracker.h>

Inheritance diagram for lti::camshiftTracker:
Inheritance graph
[legend]
Collaboration diagram for lti::camshiftTracker:
Collaboration graph
[legend]

List of all members.

Classes

class  parameters
 the parameters for the class camshiftTracker More...

Public Member Functions

 camshiftTracker ()
 camshiftTracker (const camshiftTracker &other)
virtual ~camshiftTracker ()
virtual const char * getTypeName () const
bool apply (const channel &src, rectangle &window)
bool apply (const channel8 &src, rectangle &window)
bool reset ()
bool isInitialized ()
bool isValid ()
double getOrientation ()
double getLength ()
double getWidth ()
tpoint< float > getCenter ()
camshiftTrackercopy (const camshiftTracker &other)
virtual functorclone () const
const parametersgetParameters () const

Detailed Description

This is the implementation of the CAMSHIFT (Continuously Adaptive Mean Shift) Tracking algorithm as described in: G.Bradski, "Computer Vision Face Tracking For Use in a Perceptual User Interface", IEEE Workshop on Applic.Comp.Vis.,1998.

It tracks a rectangular search window in a channel/channel8, which must contain probability information of relevant image content (e.g. a skinProbabilityMap). It uses an iterative gradient ascent algorithm, that finds the peak, which is the closest to the specified window.

Use this by calling an apply on subsequent images and thereby passing the last result. Nevertheless, it is possible to control rectangle size and position manually.

After an apply you can get Information about the distribution inside the search window (e.g. orientation). Use the getXXX() methods to do so.


Constructor & Destructor Documentation

lti::camshiftTracker::camshiftTracker (  ) 

default constructor

lti::camshiftTracker::camshiftTracker ( const camshiftTracker other  ) 

copy constructor

Parameters:
other the object to be copied
virtual lti::camshiftTracker::~camshiftTracker (  )  [virtual]

destructor


Member Function Documentation

bool lti::camshiftTracker::apply ( const channel8 src,
rectangle window 
)

Centers the given search window on the nearest probability peak.

Tracking is realised by using this rectangle in the next call of this function. Information about the distribution inside the search window is stored and can be retrieved by using the getXXXX() methods of this functor.

Parameters:
src channel8 with the source data. Should represent a probability map (prob(0)=0.0 and prob(255)=1.0)
window the tracking window. Result will be left here.
Returns:
true if apply successful or false otherwise.
bool lti::camshiftTracker::apply ( const channel src,
rectangle window 
)

Centers the given search window on the nearest probability peak.

Tracking is realised by using this rectangle in the next call of this function. Information about the distribution inside the search window is stored and can be retrieved by using the getXXXX() methods of this functor.

Parameters:
src channel with the source data. Should represent a probability map with values between 0.0 and 1.0
window the tracking window. Result will be left here.
Returns:
true if apply successful or false otherwise.
virtual functor* lti::camshiftTracker::clone (  )  const [virtual]

returns a pointer to a clone of this functor.

Implements lti::functor.

camshiftTracker& lti::camshiftTracker::copy ( const camshiftTracker other  ) 

copy data of "other" functor.

Parameters:
other the functor to be copied
Returns:
a reference to this functor object

Reimplemented from lti::functor.

tpoint<float> lti::camshiftTracker::getCenter (  ) 

Returns center of current internal distribution state.

double lti::camshiftTracker::getLength (  ) 

Returns length of current internal distribution state.

double lti::camshiftTracker::getOrientation (  ) 

Returns Main orientation (-Pi/2 to +Pi/2) of current internal distribution state.

const parameters& lti::camshiftTracker::getParameters (  )  const

returns used parameters

Reimplemented from lti::modifier.

virtual const char* lti::camshiftTracker::getTypeName (  )  const [virtual]

returns the name of this type ("camshiftTracker")

Reimplemented from lti::modifier.

double lti::camshiftTracker::getWidth (  ) 

Returns width of current internal distribution state.

bool lti::camshiftTracker::isInitialized (  ) 

Tells, if tracker is initialized.

bool lti::camshiftTracker::isValid (  ) 

Tells, if last tracking attempt delivered valid data.

bool lti::camshiftTracker::reset (  ) 

Resets the internal state but not the parameters.


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

Generated on Sat Apr 10 15:27:04 2010 for LTI-Lib by Doxygen 1.6.1