From: Paul Brossier Date: Fri, 31 Jul 2015 20:05:17 +0000 (+0200) Subject: src/*.c: fix some useless float conversion X-Git-Tag: 0.4.2~15 X-Git-Url: https://git.aubio.org/?a=commitdiff_plain;h=053495bddae15831da28ee865378ec5c62ea7408;p=aubio.git src/*.c: fix some useless float conversion --- diff --git a/src/mathutils.c b/src/mathutils.c index 766016cb..2298f468 100644 --- a/src/mathutils.c +++ b/src/mathutils.c @@ -140,7 +140,7 @@ uint_t fvec_set_window (fvec_t *win, char_t *window_type) { break; case aubio_win_parzen: for (i=0;idata[0] += SQRT (ABS (SQR (o->oldmag->data[j]) + SQR (fftgrain->norm[j]) - - 2. * o->oldmag->data[j] * fftgrain->norm[j] + - 2 * o->oldmag->data[j] * fftgrain->norm[j] * COS (o->dev1->data[j] - fftgrain->phas[j]))); /* swap old phase data (need to remember 2 frames behind)*/ o->theta2->data[j] = o->theta1->data[j]; diff --git a/src/tempo/beattracking.c b/src/tempo/beattracking.c index 5c5e01bb..548aebc5 100644 --- a/src/tempo/beattracking.c +++ b/src/tempo/beattracking.c @@ -330,7 +330,7 @@ aubio_beattracking_checkstate (aubio_beattracking_t * bt) //i.e. 3rd frame after flagstep initially set if (counter == 1 && flagstep == 1) { //check for consistency between previous beatperiod values - if (ABS (2. * rp - rp1 - rp2) < bt->g_var) { + if (ABS (2 * rp - rp1 - rp2) < bt->g_var) { //if true, can activate context dependent model flagconst = 1; counter = 0; // reset counter and flagstep