From: Paul Brossier Date: Sun, 26 Mar 2017 13:40:49 +0000 (+0200) Subject: examples/aubioonset.c: get parameters from created instances X-Git-Tag: 0.4.5~20^2~14 X-Git-Url: https://git.aubio.org/?a=commitdiff_plain;h=b67e715f833a930125968b8ccdc33380ac530d97;p=aubio.git examples/aubioonset.c: get parameters from created instances --- diff --git a/examples/aubioonset.c b/examples/aubioonset.c index d88fe04e..829597f4 100644 --- a/examples/aubioonset.c +++ b/examples/aubioonset.c @@ -62,13 +62,6 @@ int main(int argc, char **argv) { int ret = 0; examples_common_init(argc,argv); - verbmsg ("using source: %s at %dHz\n", source_uri, samplerate); - verbmsg ("onset method: %s, ", onset_method); - verbmsg ("buffer_size: %d, ", buffer_size); - verbmsg ("hop_size: %d, ", hop_size); - verbmsg ("silence: %f, ", silence_threshold); - verbmsg ("threshold: %f\n", onset_threshold); - o = new_aubio_onset (onset_method, buffer_size, hop_size, samplerate); if (o == NULL) { ret = 1; goto beach; } if (onset_threshold != 0.) @@ -78,6 +71,13 @@ int main(int argc, char **argv) { if (onset_minioi != 0.) aubio_onset_set_minioi_s (o, onset_minioi); + verbmsg ("using source: %s at %dHz\n", source_uri, samplerate); + verbmsg ("onset method: %s, ", onset_method); + verbmsg ("buffer_size: %d, ", buffer_size); + verbmsg ("hop_size: %d, ", hop_size); + verbmsg ("silence: %f, ", aubio_onset_get_silence(o)); + verbmsg ("threshold: %f\n", aubio_onset_get_threshold(o)); + onset = new_fvec (1); wavetable = new_aubio_wavetable (samplerate, hop_size);