STIRA  0.1
Public Member Functions | Static Public Member Functions | List of all members
stira::filter::SeparableFilter Class Reference

Filters an image using a separable filter kernel. More...

#include <SeparableFilter.h>

Public Member Functions

 SeparableFilter ()
 Constructor.
 
 ~SeparableFilter ()
 Destructor.
 

Static Public Member Functions

static bool RunRow (ArrayGrid< double > *pInput, ArrayGrid< double > *pOutput, double *filtx, int filterLengthX, GridExtender< double >::ExtensionType myType=GridExtender< double >::EXTEND_MIRROR)
 Applies row by row filtering on a single grid with 1 1D filter kernel. More...
 
static bool RunColumn (ArrayGrid< double > *pInputBand, ArrayGrid< double > *pOutputBand, double *filty, int filterLengthY, GridExtender< double >::ExtensionType myType=GridExtender< double >::EXTEND_MIRROR)
 Applies column by column filtering on a single grid with 1 1D filter kernel. More...
 
static ArrayGrid< double > * RunRowColumn (ArrayGrid< double > *pInput, double *filterTapX, double *filterTapY, int filterLengthX, int filterLengthY, GridExtender< double >::ExtensionType myType=GridExtender< double >::EXTEND_MIRROR)
 Applies filtering on a single grid, first row by row and then column by column. More...
 
static ArrayGrid< double > * RunColumnRow (ArrayGrid< double > *pInput, double *filterTapX, double *filterTapY, int filterLengthX, int filterLengthY, GridExtender< double >::ExtensionType myType=GridExtender< double >::EXTEND_MIRROR)
 Applies filtering on a single grid, first column by column and then row by row. More...
 
static ImageRunRowColumn (Image *pInput, double *filterTapX, double *filterTapY, int filterLengthX, int filterLengthY, GridExtender< double >::ExtensionType myType=GridExtender< double >::EXTEND_MIRROR)
 Applies filtering on a multiband image, first row by row and then column by column. More...
 
static ImageRunColumnRow (Image *pInput, double *filterTapX, double *filterTapY, int filterLengthX, int filterLengthY, GridExtender< double >::ExtensionType myType=GridExtender< double >::EXTEND_MIRROR)
 Applies filtering on a multiband image, first column by column and then row by row. More...
 
static void BasicFilter1D (double *pInputArray1D, double *pFilterKernel, double *pOutputArray1D, int inputLength, int filterLength, GridExtender< double >::ExtensionType myType=GridExtender< double >::EXTEND_MIRROR)
 Filters a one dimensional data set (a single row or column) More...
 

Detailed Description

Filters an image using a separable filter kernel.

Member Function Documentation

void stira::filter::SeparableFilter::BasicFilter1D ( double *  pInputArray1D,
double *  pFilterKernel,
double *  pOutputArray1D,
int  inputLength,
int  filterLength,
GridExtender< double >::ExtensionType  myType = GridExtender<double>::EXTEND_MIRROR 
)
static

Filters a one dimensional data set (a single row or column)

Parameters
pInputArray1D1D input array to filter (a row or a column of the image)
pFilterKernelthe 1D filter kernel
pOutputArray1Doutput array after filtering
inputLengthlength of the 1D array
filterLengthlength of the filter
myTypeidentifies how borders should be extended (mirror, tile, black)

Referenced by stira::filter::GaussConvolve::CreateBlurredBars().

bool stira::filter::SeparableFilter::RunColumn ( ArrayGrid< double > *  pInputBand,
ArrayGrid< double > *  pOutputBand,
double *  filty,
int  filterLengthY,
GridExtender< double >::ExtensionType  myType = GridExtender<double>::EXTEND_MIRROR 
)
static

Applies column by column filtering on a single grid with 1 1D filter kernel.

Parameters
pInputthe input grid
pOutputthe output grid (allocated but not necessarely initialized)
filtythe 1D filter taps
filterLengthYlength of the filter
myTypeidentifies how borders should be extended (mirrored, tiled, padded with zeros)

If the filter length is 1, the output grid is just a copy of the input grid

References stira::imagedata::ArrayGrid< T >::GetHeight(), stira::imagedata::ArrayGrid< T >::GetValue(), stira::imagedata::ArrayGrid< T >::GetWidth(), stira::imagedata::ArrayGrid< T >::SetGridValues(), and stira::imagedata::ArrayGrid< T >::SetValue().

ArrayGrid< double > * stira::filter::SeparableFilter::RunColumnRow ( ArrayGrid< double > *  pInput,
double *  filterTapX,
double *  filterTapY,
int  filterLengthX,
int  filterLengthY,
GridExtender< double >::ExtensionType  myType = GridExtender<double>::EXTEND_MIRROR 
)
static

Applies filtering on a single grid, first column by column and then row by row.

Parameters
pInputthe input grid
filterTapXthe 1D filter taps for the x direction
filterTapYthe 1D filter taps for the y direction
filterLengthXlength of the filter for the x direction
filterLengthYlength of the filter for the y direction
myTypeidentifies how borders should be extended (mirror, tile, black)

mallocs memory and returns response of input image filtered with filterTapX on the rows and filterTapY on the columns

References stira::imagedata::ArrayGrid< T >::GetHeight(), and stira::imagedata::ArrayGrid< T >::GetWidth().

Referenced by RunColumnRow().

Image * stira::filter::SeparableFilter::RunColumnRow ( Image pInput,
double *  filterTapX,
double *  filterTapY,
int  filterLengthX,
int  filterLengthY,
GridExtender< double >::ExtensionType  myType = GridExtender<double>::EXTEND_MIRROR 
)
static

Applies filtering on a multiband image, first column by column and then row by row.

Parameters
pInputthe input image
filterTapXthe 1D filter taps for the x direction
filterTapYthe 1D filter taps for the y direction
filterLengthXlength of the filter for the x direction
filterLengthYlength of the filter for the y direction
myTypeidentifies how borders should be extended (mirror, tile, black)

mallocs memory and returns response of input image filtered with filterTapX on the rows and filterTapY on the columns

References stira::imagedata::Image::AddBand(), stira::imagedata::Image::GetBands(), stira::imagedata::Image::GetHeight(), stira::imagedata::Image::GetNumberOfBands(), stira::imagedata::Image::GetWidth(), and RunColumnRow().

bool stira::filter::SeparableFilter::RunRow ( ArrayGrid< double > *  pInput,
ArrayGrid< double > *  pOutput,
double *  filtx,
int  filterLengthX,
GridExtender< double >::ExtensionType  myType = GridExtender<double>::EXTEND_MIRROR 
)
static

Applies row by row filtering on a single grid with 1 1D filter kernel.

Parameters
pInputthe input grid
pOutputthe output grid (allocated but not necessarely initialized)
filtxthe 1D filter taps
filterLengthXlength of the filter
myTypeidentifies how borders should be extended (mirrored, tiled, padded with zeros)

If the filter length is 1, the output grid is just a copy of the input grid

References stira::imagedata::ArrayGrid< T >::GetHeight(), stira::imagedata::ArrayGrid< T >::GetValue(), stira::imagedata::ArrayGrid< T >::GetWidth(), stira::imagedata::ArrayGrid< T >::SetGridValues(), and stira::imagedata::ArrayGrid< T >::SetValue().

ArrayGrid< double > * stira::filter::SeparableFilter::RunRowColumn ( ArrayGrid< double > *  pInput,
double *  filterTapX,
double *  filterTapY,
int  filterLengthX,
int  filterLengthY,
GridExtender< double >::ExtensionType  myType = GridExtender<double>::EXTEND_MIRROR 
)
static

Applies filtering on a single grid, first row by row and then column by column.

Parameters
pInputthe input grid
filterTapXthe 1D filter taps for the x direction
filterTapYthe 1D filter taps for the y direction
filterLengthXlength of the filter for the x direction
filterLengthYlength of the filter for the y direction
myTypeidentifies how borders should be extended (mirror, tile, black)

mallocs memory and returns response of input image filtered with filterTapX on the rows and filterTapY on the columns

References stira::imagedata::ArrayGrid< T >::GetHeight(), and stira::imagedata::ArrayGrid< T >::GetWidth().

Referenced by stira::filter::GaussConvolve::DerivativeConvolveSeparable(), stira::steerable::PyramidBurtAdelson::GetPyramid(), stira::steerable::ComputeSteerableFilteredImages::Run(), and RunRowColumn().

Image * stira::filter::SeparableFilter::RunRowColumn ( Image pInput,
double *  filterTapX,
double *  filterTapY,
int  filterLengthX,
int  filterLengthY,
GridExtender< double >::ExtensionType  myType = GridExtender<double>::EXTEND_MIRROR 
)
static

Applies filtering on a multiband image, first row by row and then column by column.

Parameters
pInputthe input image
filterTapXthe 1D filter taps for the x direction
filterTapYthe 1D filter taps for the y direction
filterLengthXlength of the filter for the x direction
filterLengthYlength of the filter for the y direction
myTypeidentifies how borders should be extended (mirror, tile, black)

mallocs memory and returns response of input image filtered with filterTapX on the rows and filterTapY on the columns

References stira::imagedata::Image::AddBand(), stira::imagedata::Image::GetBands(), stira::imagedata::Image::GetHeight(), stira::imagedata::Image::GetNumberOfBands(), stira::imagedata::Image::GetWidth(), and RunRowColumn().


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