Marsyas  0.6.0-alpha
/usr/src/RPM/BUILD/marsyas-0.6.0/src/marsyas/Transcriber.h
Go to the documentation of this file.
00001 #ifndef MARSYAS_TRANSCRIBER_H
00002 #define MARSYAS_TRANSCRIBER_H
00003 
00004 #include <marsyas/system/MarSystemManager.h>
00005 #include "TranscriberExtract.h"
00006 //using namespace std;
00007 namespace Marsyas
00008 {
00017 class Transcriber: public TranscriberExtract
00018 {
00019 
00020 public:
00021   Transcriber();
00022   ~Transcriber();
00023 
00025 
00026 
00027 
00028   static mrs_real findMedianWithoutZeros(const mrs_natural start,
00029                                          const mrs_natural length,
00030                                          const realvec& array);
00031   static realvec findValleys(const realvec& list);
00032   static realvec findPeaks(const realvec& list, const
00033                            mrs_real cutoff);
00034   static mrs_real findNextPeakValue(const realvec& list,
00035                                     const mrs_natural start);
00037 
00038 
00041   static void pitchSegment(const realvec& pitchList,
00042                            realvec& boundaries, const mrs_natural width);
00043   static realvec findPitchBoundaries(const realvec&
00044                                      pitchList, const mrs_natural width);
00046 
00047 
00050   static void ampSegment(const realvec& ampList, realvec&
00051                          boundaries,const mrs_real cutoff);
00052   static void filterAmpBoundaries(realvec& ampList, realvec&
00053                                   boundaries);
00054   static void discardEndingTotalSilenceAmpsOnly(realvec& ampList);
00056 
00057 
00060   static realvec getNotes(const realvec& pitchList, const realvec&
00061                           ampList, const realvec& boundaries);
00062   static void discardBeginEndSilences(const realvec& pitchList, const
00063                                       realvec& ampList, realvec& boundaries);
00064   static void discardBeginEndSilencesAmpsOnly(const realvec& ampList,
00065       realvec& boundaries);
00066   static void getRelativeDurations(const realvec& boundaries,
00067                                    realvec &durations);
00069 
00070 };
00071 }
00072 #endif
00073