source: flair-src/trunk/lib/FlairFilter/src/ButterworthLowPass.cpp @ 7

Last change on this file since 7 was 7, checked in by Sanahuja Guillaume, 5 years ago

filter and meta

File size: 1.4 KB
Line 
1//  created:    2013/12/10
2//  filename:   ButterworthLowPass.cpp
3//
4//  author:     Guillaume Sanahuja
5//              Copyright Heudiasyc UMR UTC/CNRS 7253
6//
7//  version:    $Id: $
8//
9//  purpose:    Class defining a Butterworth low pass filter
10//
11//
12/*********************************************************************/
13
14#include "ButterworthLowPass.h"
15#include "ButterworthLowPass_impl.h"
16#include <cvmatrix.h>
17#include <Layout.h>
18#include <LayoutPosition.h>
19
20using std::string;
21using namespace flair::core;
22using namespace flair::gui;
23
24namespace flair
25{
26namespace filter
27{
28
29ButterworthLowPass::ButterworthLowPass(const IODevice* parent,const LayoutPosition* position,string name,int order): IODevice(parent,name)
30{
31    pimpl_=new ButterworthLowPass_impl(this,position,name,order);
32    AddDataToLog(pimpl_->output);
33}
34
35ButterworthLowPass::ButterworthLowPass(const gui::LayoutPosition* position,string name,int order): IODevice(position->getLayout(),name)
36{
37    pimpl_=new ButterworthLowPass_impl(this,position,name,order);
38    AddDataToLog(pimpl_->output);
39}
40
41
42ButterworthLowPass::~ButterworthLowPass()
43{
44    delete pimpl_;
45}
46
47cvmatrix *ButterworthLowPass::Matrix(void) const
48{
49    return pimpl_->output;
50}
51
52float ButterworthLowPass::Output(void) const
53{
54   return pimpl_->output->Value(0,0);
55}
56
57void ButterworthLowPass::UpdateFrom(const io_data *data)
58{
59    pimpl_->UpdateFrom(data);
60    ProcessUpdate(pimpl_->output);
61}
62
63} // end namespace filter
64} // end namespace flair
Note: See TracBrowser for help on using the repository browser.