feature/autosinkfeature/cnnfeature/cnn_orgfeature/constantqfeature/crepefeature/crepe_orgfeature/pitchshiftfeature/pydocstringsfeature/timestretchfix/ffmpeg5pitchshiftsamplertimestretchyinfft+
Last change
on this file since 87636d0 was
158e031,
checked in by Paul Brossier <piem@piem.org>, 11 years ago
|
tests/: add void to prototypes to build with -Wstrict-prototypes
|
-
Property mode set to
100644
|
File size:
756 bytes
|
Rev | Line | |
---|
[4e9101e] | 1 | #include <aubio.h> |
---|
[7e35b37] | 2 | #include <math.h> |
---|
| 3 | #include <stdio.h> |
---|
[4e9101e] | 4 | |
---|
[158e031] | 5 | int main (void) |
---|
[4e9101e] | 6 | { |
---|
[7e35b37] | 7 | uint_t length = 0; |
---|
| 8 | uint_t n_length = 4, n_types = 10, i, t; |
---|
| 9 | uint_t lengths[4] = { 8, 10, 15, 16 }; |
---|
| 10 | char *method = "default"; |
---|
| 11 | char *window_types[10] = { "default", |
---|
| 12 | "rectangle", "hamming", "hanning", "hanningz", |
---|
| 13 | "blackman", "blackman_harris", "gaussian", "welch", "parzen"}; |
---|
| 14 | |
---|
| 15 | for ( t = 0; t < n_types; t ++ ) { |
---|
| 16 | for ( i = 0; i < n_length; i++) |
---|
| 17 | { |
---|
| 18 | length = lengths[i]; |
---|
| 19 | method = window_types[t]; |
---|
| 20 | |
---|
| 21 | fvec_t * window = new_aubio_window(method, length); |
---|
| 22 | |
---|
| 23 | fvec_set_window(window, method); |
---|
| 24 | fprintf(stdout, "length: %d, method: %s, window:, ", length, method); |
---|
| 25 | fvec_print(window); |
---|
| 26 | |
---|
| 27 | del_fvec(window); |
---|
| 28 | } |
---|
[4e9101e] | 29 | } |
---|
| 30 | return 0; |
---|
| 31 | } |
---|
| 32 | |
---|
Note: See
TracBrowser
for help on using the repository browser.