#include "rubberband/rubberband-c.h"
#define MIN_STRETCH_RATIO 0.025
-#define MAX_STRETCH_RATIO 10.
+#define MAX_STRETCH_RATIO 40.
/** generic time stretching structure */
struct _aubio_timestretch_t
{
if (stretch >= MIN_STRETCH_RATIO && stretch <= MAX_STRETCH_RATIO) {
p->stretchratio = stretch;
- rubberband_set_time_ratio(p->rb, p->stretchratio);
+ rubberband_set_time_ratio(p->rb, 1./p->stretchratio);
return AUBIO_OK;
} else {
AUBIO_ERR("timestretch: could not set stretch ratio to %.2f\n", stretch);