Mercurial > hg > silvet
comparison src/Silvet.h @ 319:c37da62ba4e5 livemode
Add onsets output (lower-latency than the notes output)
author | Chris Cannam |
---|---|
date | Wed, 29 Apr 2015 09:27:38 +0100 |
parents | f3e10617a60d |
children | 7f9683c8de69 |
comparison
equal
deleted
inserted
replaced
318:ba02cdc839db | 319:c37da62ba4e5 |
---|---|
114 | 114 |
115 vector<double> postProcess(const vector<double> &pitches, | 115 vector<double> postProcess(const vector<double> &pitches, |
116 const vector<int> &bestShifts, | 116 const vector<int> &bestShifts, |
117 bool wantShifts); // -> piano roll column | 117 bool wantShifts); // -> piano roll column |
118 | 118 |
119 FeatureList noteTrack(int shiftCount); | 119 std::pair<FeatureList, FeatureList> noteTrack(int shiftCount); // notes, onsets |
120 | 120 |
121 void emitNote(int start, int end, int note, int shiftCount, | 121 void emitNote(int start, int end, int note, int shiftCount, |
122 FeatureList ¬eFeatures); | |
123 | |
124 void emitOnset(int start, int note, int shiftCount, | |
122 FeatureList ¬eFeatures); | 125 FeatureList ¬eFeatures); |
123 | 126 |
124 Vamp::RealTime getColumnTimestamp(int column); | 127 Vamp::RealTime getColumnTimestamp(int column); |
125 | 128 |
126 Feature makeNoteFeature(int start, int end, int note, int shift, | 129 Feature makeNoteFeature(int start, int end, int note, int shift, |
127 int shiftCount, int velocity); | 130 int shiftCount, int velocity); |
131 Feature makeOnsetFeature(int start, int note, int shift, | |
132 int shiftCount, int velocity); | |
128 | 133 |
129 float getInputGainAt(Vamp::RealTime t); | 134 float getInputGainAt(Vamp::RealTime t); |
130 | 135 |
131 void insertTemplateFeatures(FeatureSet &); | 136 void insertTemplateFeatures(FeatureSet &); |
132 | 137 |
141 int m_resampledCount; | 146 int m_resampledCount; |
142 Vamp::RealTime m_startTime; | 147 Vamp::RealTime m_startTime; |
143 bool m_haveStartTime; | 148 bool m_haveStartTime; |
144 | 149 |
145 mutable int m_notesOutputNo; | 150 mutable int m_notesOutputNo; |
151 mutable int m_onsetsOutputNo; | |
146 mutable int m_fcqOutputNo; | 152 mutable int m_fcqOutputNo; |
147 mutable int m_pitchOutputNo; | 153 mutable int m_pitchOutputNo; |
148 mutable int m_templateOutputNo; | 154 mutable int m_templateOutputNo; |
149 mutable int m_chromaOutputNo; | 155 mutable int m_chromaOutputNo; |
150 }; | 156 }; |