From: Paul Brossier Date: Mon, 26 Nov 2018 16:23:14 +0000 (+0100) Subject: [tests] add calls to new_aubio_mfcc with wrong input parameters X-Git-Tag: 0.4.9~148 X-Git-Url: https://git.aubio.org/?a=commitdiff_plain;h=b1743190b26e5424eb6102c81ff449c7170bd75b;p=aubio.git [tests] add calls to new_aubio_mfcc with wrong input parameters --- diff --git a/tests/src/spectral/test-mfcc.c b/tests/src/spectral/test-mfcc.c index 23f8c64e..b5ec4343 100644 --- a/tests/src/spectral/test-mfcc.c +++ b/tests/src/spectral/test-mfcc.c @@ -4,13 +4,18 @@ int main (void) { uint_t win_s = 512; // fft size uint_t n_filters = 40; // number of filters - uint_t n_coefs = 13; // number of coefficients + uint_t n_coeffs = 13; // number of coefficients smpl_t samplerate = 16000.; // samplerate cvec_t *in = new_cvec (win_s); // input buffer - fvec_t *out = new_fvec (n_coefs); // output coefficients + fvec_t *out = new_fvec (n_coeffs); // output coefficients + + if (new_aubio_mfcc( 0, n_filters, n_coeffs, samplerate)) return 1; + if (new_aubio_mfcc(win_s, 0, n_coeffs, samplerate)) return 1; + if (new_aubio_mfcc(win_s, n_filters, 0, samplerate)) return 1; + if (new_aubio_mfcc(win_s, n_filters, n_coeffs, 0)) return 1; // create mfcc object - aubio_mfcc_t *o = new_aubio_mfcc (win_s, n_filters, n_coefs, samplerate); + aubio_mfcc_t *o = new_aubio_mfcc (win_s, n_filters, n_coeffs, samplerate); cvec_norm_set_all (in, 1.); aubio_mfcc_do (o, in, out);