Changeset 4621cd6 for examples/aubiotrack.c
- Timestamp:
- Dec 4, 2009, 1:46:40 AM (14 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:
- aea235c
- Parents:
- c17a0ee
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
examples/aubiotrack.c
rc17a0ee r4621cd6 29 29 30 30 static int aubio_process(smpl_t **input, smpl_t **output, int nframes) { 31 unsigned int i; /*channels*/32 31 unsigned int j; /*frames*/ 33 32 for (j=0;j<(unsigned)nframes;j++) { 34 33 if(usejack) { 35 for (i=0;i<channels;i++) { 36 /* write input to datanew */ 37 fvec_write_sample(ibuf, input[i][j], i, pos); 38 /* put synthnew in output */ 39 output[i][j] = fvec_read_sample(obuf, i, pos); 40 } 34 /* write input to datanew */ 35 fvec_write_sample(ibuf, input[0][j], pos); 36 /* put synthnew in output */ 37 output[0][j] = fvec_read_sample(obuf, pos); 41 38 } 42 39 /*time for fft*/ … … 44 41 /* block loop */ 45 42 aubio_tempo_do (bt,ibuf,tempo_out); 46 istactus = fvec_read_sample (tempo_out, 0 , 0);47 isonset = fvec_read_sample (tempo_out, 0,1);43 istactus = fvec_read_sample (tempo_out, 0); 44 isonset = fvec_read_sample (tempo_out, 1); 48 45 if (istactus > 0.) { 49 46 fvec_copy (woodblock, obuf); … … 76 73 examples_common_init(argc,argv); 77 74 78 tempo_out = new_fvec(2 ,channels);79 bt = new_aubio_tempo(onset_mode,buffer_size,overlap_size, channels,samplerate);75 tempo_out = new_fvec(2); 76 bt = new_aubio_tempo(onset_mode,buffer_size,overlap_size, samplerate); 80 77 if (threshold != 0.) aubio_tempo_set_threshold (bt, threshold); 81 78
Note: See TracChangeset
for help on using the changeset viewer.