00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019 #ifndef MARSYAS_Resample_H
00020 #define MARSYAS_Resample_H
00021
00022 #include "MarSystem.h"
00023
00024
00025 #include "ResampleLinear.h"
00026 #include "ResampleBezier.h"
00027 #include "ResampleSinc.h"
00028 #include "ResampleNearestNeighbour.h"
00029
00030
00031 namespace Marsyas
00032 {
00054 class marsyas_EXPORT Resample: public MarSystem
00055 {
00056
00057
00058
00059
00060
00061 private:
00062
00063 void addControls();
00064 MarControlPtr ctrl_option_;
00065 MarControlPtr ctrl_samplingRateAdjustmentMode_;
00066 MarControlPtr ctrl_offStart_;
00067 MarControlPtr ctrl_offEnd_;
00068 MarControlPtr ctrl_newSamplingRate_;
00069 MarControlPtr ctrl_resamplingMode_;
00070 MarSystem* interpolator_;
00071 ResampleBezier* resabez_;
00072 ResampleLinear* resalin_;
00073 ResampleSinc* resasinc_;
00074
00075 void myUpdate(MarControlPtr sender);
00076
00077
00078 public:
00079 Resample(std::string name);
00080 Resample(const Resample& a);
00081 ~Resample();
00082 MarSystem* clone() const;
00083
00084
00085 void myProcess(realvec& in, realvec& out);
00086
00087
00088 };
00089
00090 }
00091
00092 #endif