BLInterpolation

class BLInterpolation : public tsa::AlgoBase

Band limited interpolation.

User interface

BLInterpolation &Input(SeqViewDouble &indata)

Add data to be resampled. This method can be called repeatedly, each time with a different chunk of data. The chunks are considered as consecutive pieces of a continuous stream.

Return

a reference to an instance of this class

Pre

the number of rows in indata must be equal to the number of channels

Parameters
  • indata: view containing input data

BLInterpolation &Output(SeqViewDouble &outdata)

Get resampled data. If there are enough resampled data available these are returned, otherwise an exception is raised.

Return

a reference to an instance of this class

Post

if no exception is raised outdata has a number of rows equal to the number of channels and a number of columns equal to the number of returned data

Parameters
  • outdata: view which will be filled with resampled data

Exceptions
  • no_data_available: there are not enough resampled data available

Getters

unsigned int GetData(Dmatrix &outdata)

Get resampled data

Return

the number of resampled data returned

Parameters
  • outdata: a matrix which will be filled with resampled data

double GetStartTime()

Start time of the next sequence of resampled data.

Return

the start time of the next sequence of resampled data

Setters

void SetData(Dmatrix &indata, double scale)

Add data to be resampled

Parameters
  • indata: a matrix which contains input data

  • scale: a scale parameter for input data

Public Functions

BLInterpolation(unsigned int channels, unsigned int outdata, unsigned int irate, unsigned int orate, unsigned int order, double alpha = 1.0, enum NormalizationType nt = NONormalization)

Constructor.

Parameters
  • channels: number of channels

  • outdata: number of resampled data returned at each call

  • irate: input rate

  • orate: output rate

  • order: order of filter

  • alpha: window parameter

BLInterpolation(const BLInterpolation &from)

Copy constructor

Parameters
  • from: The instance that must be copied

~BLInterpolation()

Destructor

BLInterpolation &operator=(const BLInterpolation &from)

Assignement operator

Return

a reference to a new object

Parameters
  • from: The instance to be assigned from