ref: e47ade3a8ec171fb24a7b38126070851c81ca599
parent: b1585fd39d984dec889da2633159658cc872d8f7
author: Paul Brossier <piem@altern.org>
date: Thu Apr 20 08:49:06 EDT 2006
mcomb: bypass hack for high freqs, use instfreq rather than interp mcomb: bypass hack for high freqs, use instfreq rather than interp
--- a/src/pitchmcomb.c
+++ b/src/pitchmcomb.c
@@ -111,6 +111,7 @@
for (j=0; j< p->theta->length; j++) {
p->theta->data[i][j]=fftgrain->phas[i][j];
}
+ //return p->candidates[p->goodcandidate]->ebin;
return FLOOR(p->candidates[p->goodcandidate]->ebin+.5) + instfreq;
/*} else {
return -1.;
@@ -202,6 +203,9 @@
/* get the biggest peak in the spectrum */
root_peak = aubio_pitchmcomb_get_root_peak(peaks,count);
+ /* not enough partials in highest notes, could be forced */
+ //if (peaks[root_peak].ebin >= aubio_miditofreq(85.)/p->tau) N=2;
+ //if (peaks[root_peak].ebin >= aubio_miditofreq(90.)/p->tau) N=1;
/* now calculate the energy of each of the 5 combs */
for (l=0;l<M;l++) {
smpl_t scaler = (1./(l+1.));