]> code.delx.au - pulseaudio/blobdiff - src/pulsecore/time-smoother.c
Merge remote branch 'mkbosmans/rate-adjustment'
[pulseaudio] / src / pulsecore / time-smoother.c
index 1371ad562ef51f058cdc27434938ad051c284f91..0696cabc2c6ef4ce22c388b7ccded3dd791dbcb1 100644 (file)
@@ -320,10 +320,8 @@ static void estimate(pa_smoother *s, pa_usec_t x, pa_usec_t *y, double *deriv) {
 
         calc_abc(s);
 
-        tx = (double) x;
-
         /* Move to origin */
-        tx -= (double) s->ex;
+        tx = (double) (x - s->ex);
 
         /* Horner scheme */
         ty = (tx * (s->c + tx * (s->b + tx * s->a)));