|
latest version v1.9 - last update 10 Apr 2010 |
|
This functor is used to downsample images. More...
#include <ltiDownsampling.h>


Classes | |
| class | parameters |
| the parameters for the class downsampling More... | |
Public Member Functions | |
| downsampling () | |
| downsampling (const parameters &par) | |
| downsampling (const mathObject &aKernel) | |
| downsampling (const downsampling &other) | |
| virtual | ~downsampling () |
| virtual const char * | getTypeName () const |
| bool | apply (channel8 &srcdest) const |
| bool | apply (matrix< float > &srcdest) const |
| bool | apply (dmatrix &srcdest) const |
| bool | apply (image &srcdest) const |
| bool | apply (vector< channel8::value_type > &srcdest) const |
| bool | apply (vector< channel::value_type > &srcdest) const |
| bool | apply (const channel8 &src, channel8 &dest) const |
| bool | apply (const matrix< float > &src, matrix< float > &dest) const |
| bool | apply (const dmatrix &src, dmatrix &dest) const |
| bool | apply (const image &src, image &dest) const |
| bool | apply (const vector< channel8::value_type > &src, vector< channel8::value_type > &dest) const |
| bool | apply (const vector< channel::value_type > &src, vector< channel::value_type > &dest) const |
| downsampling & | copy (const downsampling &other) |
| virtual functor * | clone () const |
| const parameters & | getParameters () const |
| void | setKernel (const mathObject &aKernel) |
This functor is used to downsample images.
Here, the process of downsampling means to first filter the image with (usually) a low pass filter, and then take each n-th pixel, where n is an integer number.
The downsampling::parameters specify which kind of filter should be used and which downsampling factor. If you do not want or need to low-pass filter the image first, than take a look at lti::decimation.
If you need to "downsample" an image with a non-integer factor take a look to lti::scaling.
Example:
#include "ltiDownsampling.h" #include "ltiGaussKernel2D.h" lti::channel chnl1,chnl2; ... lti::downsampling downsampler; // downsampling functor lti::downsampling::parameters param; // downsampling parameters // a gaussian kernel to use before the downsampling lti::gaussKernel2D<lti::channel::value_type> gkernel; param.setKernel(gkernel); // use the gaussian kernel downsampler.setParameters(param); // use the given parameters downsampler.apply(chnl1,chnl2); // channel 1 will be downsampled an the // result will be left on channel 2.
| lti::downsampling::downsampling | ( | ) |
default constructor
| lti::downsampling::downsampling | ( | const parameters & | par | ) |
Constructor with parameters object.
| lti::downsampling::downsampling | ( | const mathObject & | aKernel | ) |
create a downsampling functor with a parameter set which includes the given filter kernel
| lti::downsampling::downsampling | ( | const downsampling & | other | ) |
copy constructor
| other | the object to be copied |
| virtual lti::downsampling::~downsampling | ( | ) | [virtual] |
destructor
| bool lti::downsampling::apply | ( | const vector< channel::value_type > & | src, | |
| vector< channel::value_type > & | dest | |||
| ) | const [virtual] |
operates on a copy of the given parameters.
| src | vector<channel::value_type> with the source data. | |
| dest | vector<channel::value_type> where the result will be left. |
Reimplemented from lti::modifier.
| bool lti::downsampling::apply | ( | const vector< channel8::value_type > & | src, | |
| vector< channel8::value_type > & | dest | |||
| ) | const |
operates on a copy of the given parameters.
| src | vector<channel8::value_type> with the source data. | |
| dest | vector<channel8::value_type> where the result will be left. |
downsample a color image by splitting it into the RGB components, downsampling each channel and merging the results
Reimplemented from lti::modifier.
operates on a copy of the given parameters.
| src | dmatrix with the source data. | |
| dest | dmatrix where the result will be left. |
| bool lti::downsampling::apply | ( | const matrix< float > & | src, | |
| matrix< float > & | dest | |||
| ) | const [virtual] |
operates on a copy of the given parameters.
Reimplemented from lti::modifier.
operates on a copy of the given parameters.
Reimplemented from lti::modifier.
| bool lti::downsampling::apply | ( | vector< channel::value_type > & | srcdest | ) | const |
operates on the given parameter.
| srcdest | vector<channel::value_type> with the source data. The result will be left here too. |
Reimplemented from lti::modifier.
| bool lti::downsampling::apply | ( | vector< channel8::value_type > & | srcdest | ) | const |
operates on the given parameter.
| srcdest | vector<channel8::value_type> with the source data. The result will be left here too. |
| bool lti::downsampling::apply | ( | image & | srcdest | ) | const [virtual] |
downsample a color image by splitting it into the RGB components, downsampling each channel and merging the results
| srcdest | image with the source data. The result will be left here too. |
Reimplemented from lti::modifier.
| bool lti::downsampling::apply | ( | dmatrix & | srcdest | ) | const |
operates on the given parameter.
| srcdest | dmatrix with the source data. The result will be left here too. |
| bool lti::downsampling::apply | ( | matrix< float > & | srcdest | ) | const [virtual] |
operates on the given parameter.
| srcdest | channel with the source data. The result will be left here too. |
Reimplemented from lti::modifier.
| bool lti::downsampling::apply | ( | channel8 & | srcdest | ) | const [virtual] |
operates on the given parameter.
| srcdest | channel8 with the source data. The result will be left here too. |
Reimplemented from lti::modifier.
| virtual functor* lti::downsampling::clone | ( | ) | const [virtual] |
returns a pointer to a clone of this functor.
Implements lti::functor.
| downsampling& lti::downsampling::copy | ( | const downsampling & | other | ) |
copy data of "other" functor.
| other | the functor to be copied |
Reimplemented from lti::functor.
| const parameters& lti::downsampling::getParameters | ( | ) | const |
returns used parameters
Reimplemented from lti::modifier.
| virtual const char* lti::downsampling::getTypeName | ( | ) | const [virtual] |
returns the name of this type ("downsampling")
Reimplemented from lti::modifier.
| void lti::downsampling::setKernel | ( | const mathObject & | aKernel | ) |