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

lti::decimation Class Reference

Decimation. More...

#include <ltiDecimation.h>

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

List of all members.

Classes

class  parameters
 the parameters for the class decimation More...

Public Member Functions

 decimation ()
 decimation (const point &factor)
 decimation (const decimation &other)
virtual ~decimation ()
virtual const char * getTypeName () const
template<class T >
bool apply (matrix< T > &srcdest) const
template<class T >
bool apply (vector< T > &srcdest) const
template<class T >
bool apply (const matrix< T > &src, matrix< T > &dest) const
template<class T >
bool apply (const vector< T > &src, vector< T > &dest) const
decimationcopy (const decimation &other)
virtual functorclone () const
const parametersgetParameters () const

Detailed Description

Decimation.

To decimate an image or matrix means to take each n-th pixel. It is much simpler than lti::downsampling, which also applies a filter kernel before the decimation.

You may also be interersted in lti::scaling, which uses interpolation to downsample at non-integer scales.

See also:
lti::upsampling, lti::filledUpsampling, lti::downsampling, lti::scaling

Constructor & Destructor Documentation

lti::decimation::decimation (  ) 

default constructor

lti::decimation::decimation ( const point factor  ) 

constructor with a default parameters with the decimation factor given by the point factor.

(see lti::decimation::parameters::factor)

lti::decimation::decimation ( const decimation other  ) 

copy constructor

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

destructor


Member Function Documentation

template<class T >
bool lti::decimation::apply ( const vector< T > &  src,
vector< T > &  dest 
) const [inline]

operates on a copy of the given parameters.

Parameters:
src vector<T> with the source data.
dest vector<T> where the result will be left.
Returns:
true if successful, false otherwise.

References lti::genericVector< T >::at(), lti::genericVector< T >::begin(), lti::genericVector< T >::end(), getParameters(), and lti::genericVector< T >::resize().

template<class T >
bool lti::decimation::apply ( const matrix< T > &  src,
matrix< T > &  dest 
) const [inline]

operates on a copy of the given parameters.

Parameters:
src matrix<T> with the source data.
dest matrix<T> where the result will be left.
Returns:
true if successful, false otherwise.

References lti::genericMatrix< T >::at(), lti::genericVector< T >::begin(), lti::genericMatrix< T >::columns(), lti::genericVector< T >::end(), getParameters(), lti::matrix< T >::getRow(), lti::genericMatrix< T >::resize(), lti::genericMatrix< T >::rows(), lti::tpoint< T >::x, and lti::tpoint< T >::y.

template<class T >
bool lti::decimation::apply ( vector< T > &  srcdest  )  const [inline]

operates on the given parameter.

Parameters:
srcdest vector<T> with the source data. The result will be left here too.
Returns:
true if successful, false otherwise.

References apply(), and lti::genericVector< T >::detach().

template<class T >
bool lti::decimation::apply ( matrix< T > &  srcdest  )  const [inline]

operates on the given parameter.

Parameters:
srcdest matrix<T> with the source data. The result will be left here too.
Returns:
true if successful, false otherwise.

References lti::genericMatrix< T >::detach().

Referenced by apply().

virtual functor* lti::decimation::clone (  )  const [virtual]

returns a pointer to a clone of this functor.

Implements lti::functor.

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

copy data of "other" functor.

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

Reimplemented from lti::functor.

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

returns used parameters

Reimplemented from lti::modifier.

Referenced by apply().

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

returns the name of this type ("decimation")

Reimplemented from lti::modifier.


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

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