Changeset 72db1cf
- Timestamp:
- Feb 10, 2013, 3:18:37 AM (12 years ago)
- Branches:
- feature/autosink, feature/cnn, feature/cnn_org, feature/constantq, feature/crepe, feature/crepe_org, feature/pitchshift, feature/pydocstrings, feature/timestretch, fix/ffmpeg5, master, pitchshift, sampler, timestretch, yinfft+
- Children:
- 320ce80
- Parents:
- ce12f3a
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/tempo/beattracking.c
rce12f3a r72db1cf 136 136 smpl_t beat; // beat position 137 137 smpl_t bp; // beat period 138 uint_t a ; sint_t b;// used to build shift invariant comb filterbank138 uint_t a, b; // used to build shift invariant comb filterbank 139 139 uint_t kmax; // number of elements used to find beat phase 140 140 … … 160 160 for (i = 1; i < laglen - 1; i++) { 161 161 for (a = 1; a <= numelem; a++) { 162 for (b = (1 - a); b < (sint_t)a; b++) {163 bt->acfout->data[i] += bt->acf->data[ a * (i + 1)+ b - 1]162 for (b = 1; b < 2 * a; b++) { 163 bt->acfout->data[i] += bt->acf->data[i * a + b - 1] 164 164 * 1. / (2. * a - 1.); 165 165 } … … 276 276 aubio_beattracking_checkstate (aubio_beattracking_t * bt) 277 277 { 278 uint_t i, j, a ; sint_tb;278 uint_t i, j, a, b; 279 279 uint_t flagconst = 0; 280 280 sint_t counter = bt->counter; … … 300 300 for (i = 1; i < laglen - 1; i++) { 301 301 for (a = 1; a <= bt->timesig; a++) { 302 for (b = (1 - a); b < (sint_t)a; b++) {303 acfout->data[i] += acf->data[ a * (i + 1)+ b - 1];302 for (b = 1; b < 2 * a; b++) { 303 acfout->data[i] += acf->data[i * a + b - 1]; 304 304 } 305 305 }
Note: See TracChangeset
for help on using the changeset viewer.