comparison dsp/keydetection/GetKeyMode.h @ 478:c92718cc6ef1

Untabify, indent, tidy
author Chris Cannam <cannam@all-day-breakfast.com>
date Thu, 30 May 2019 18:40:16 +0100
parents 64fc3009d0a3
children d48276a3ae24
comparison
equal deleted inserted replaced
477:fa407c1d9923 478:c92718cc6ef1
18 18
19 19
20 class GetKeyMode 20 class GetKeyMode
21 { 21 {
22 public: 22 public:
23 GetKeyMode( int sampleRate, float tuningFrequency, 23 GetKeyMode( int sampleRate, float tuningFrequency,
24 double hpcpAverage, double medianAverage ); 24 double hpcpAverage, double medianAverage );
25 25
26 virtual ~GetKeyMode(); 26 virtual ~GetKeyMode();
27 27
28 int process( double* PCMData ); 28 int process( double* PCMData );
29 29
30 double krumCorr( const double *pDataNorm, const double *pProfileNorm, 30 double krumCorr( const double *pDataNorm, const double *pProfileNorm,
31 int shiftProfile, unsigned int length ); 31 int shiftProfile, unsigned int length );
32 32
33 unsigned int getBlockSize() { return m_ChromaFrameSize*m_DecimationFactor; } 33 unsigned int getBlockSize() { return m_ChromaFrameSize*m_DecimationFactor; }
34 unsigned int getHopSize() { return m_ChromaHopSize*m_DecimationFactor; } 34 unsigned int getHopSize() { return m_ChromaHopSize*m_DecimationFactor; }
35 35
36 double* getChroma() { return m_ChrPointer; } 36 double* getChroma() { return m_ChrPointer; }
37 unsigned int getChromaSize(); 37 unsigned int getChromaSize();
38 38
39 double* getMeanHPCP() { return m_MeanHPCP; } 39 double* getMeanHPCP() { return m_MeanHPCP; }
40 40
41 double* getKeyStrengths(); 41 double* getKeyStrengths();
42 42
43 bool isModeMinor( int key ); 43 bool isModeMinor( int key );
44 44
45 protected: 45 protected:
46 46
47 double m_hpcpAverage; 47 double m_hpcpAverage;
48 double m_medianAverage; 48 double m_medianAverage;
49 unsigned int m_DecimationFactor; 49 unsigned int m_DecimationFactor;
50 50
51 //Decimator (fixed) 51 //Decimator (fixed)
52 Decimator* m_Decimator; 52 Decimator* m_Decimator;
53 53
54 //chroma configuration 54 //chroma configuration
55 ChromaConfig m_ChromaConfig; 55 ChromaConfig m_ChromaConfig;
56 56
57 //Chromagram object 57 //Chromagram object
58 Chromagram* m_Chroma; 58 Chromagram* m_Chroma;
59 59
60 //Chromagram output pointer 60 //Chromagram output pointer
61 double* m_ChrPointer; 61 double* m_ChrPointer;
62 62
63 //Framesize 63 //Framesize
64 unsigned int m_ChromaFrameSize; 64 unsigned int m_ChromaFrameSize;
65 //Hop 65 //Hop
66 unsigned int m_ChromaHopSize; 66 unsigned int m_ChromaHopSize;
67 67
68 68
69 unsigned int m_ChromaBuffersize; 69 unsigned int m_ChromaBuffersize;
70 unsigned int m_MedianWinsize; 70 unsigned int m_MedianWinsize;
71 71
72 unsigned int m_bufferindex; 72 unsigned int m_bufferindex;
73 unsigned int m_ChromaBufferFilling; 73 unsigned int m_ChromaBufferFilling;
74 unsigned int m_MedianBufferFilling; 74 unsigned int m_MedianBufferFilling;
75 75
76 76
77 double* m_DecimatedBuffer; 77 double* m_DecimatedBuffer;
78 double* m_ChromaBuffer; 78 double* m_ChromaBuffer;
79 double* m_MeanHPCP; 79 double* m_MeanHPCP;
80 80
81 double* m_MajProfileNorm; 81 double* m_MajProfileNorm;
82 double* m_MinProfileNorm; 82 double* m_MinProfileNorm;
83 double* m_MajCorr; 83 double* m_MajCorr;
84 double* m_MinCorr; 84 double* m_MinCorr;
85 int* m_MedianFilterBuffer; 85 int* m_MedianFilterBuffer;
86 int* m_SortedBuffer; 86 int* m_SortedBuffer;
87 87
88 double *m_keyStrengths; 88 double *m_keyStrengths;
89 }; 89 };
90 90
91 #endif // !defined GETKEYMODE_H 91 #endif // !defined GETKEYMODE_H