aboutsummaryrefslogtreecommitdiff
path: root/cyclone/sickle/rampsmooth.c
diff options
context:
space:
mode:
authorN.N. <krzyszcz@users.sourceforge.net>2005-11-21 22:16:37 +0000
committerN.N. <krzyszcz@users.sourceforge.net>2005-11-21 22:16:37 +0000
commitc2014a0a771e621cec552c6ee88daddcb46d13fe (patch)
tree183540090b25920599d86cddfa03e37cefe45dec /cyclone/sickle/rampsmooth.c
parenta1ef2f36df1754e1146a8ed50c9ac6a1b0f33697 (diff)
cyclone alpha55 (see notes.txt for cyclone and shared)
svn path=/trunk/externals/miXed/; revision=4011
Diffstat (limited to 'cyclone/sickle/rampsmooth.c')
-rw-r--r--cyclone/sickle/rampsmooth.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/cyclone/sickle/rampsmooth.c b/cyclone/sickle/rampsmooth.c
index c2023d8..848e304 100644
--- a/cyclone/sickle/rampsmooth.c
+++ b/cyclone/sickle/rampsmooth.c
@@ -3,8 +3,10 @@
* WARRANTIES, see the file, "LICENSE.txt," in this distribution. */
#include "m_pd.h"
+#include "shared.h"
#include "sickle/sic.h"
+/* LATER select the mode fitter-optionally */
#define RAMPSMOOTH_GEOMETRIC /* geometric series (same as slide~) CHECKED */
#ifndef RAMPSMOOTH_GEOMETRIC
#define RAMPSMOOTH_LINEAR
@@ -82,8 +84,8 @@ static t_int *rampsmooth_perform(t_int *w)
}
else *out++ = target;
}
- x->x_last = last;
- x->x_target = target;
+ x->x_last = (PD_BIGORSMALL(last) ? 0. : last);
+ x->x_target = (PD_BIGORSMALL(target) ? 0. : target);
x->x_incr = incr;
x->x_nleft = nleft;
return (w + 5);
@@ -120,7 +122,7 @@ static t_int *rampsmooth_perform(t_int *w)
}
*out++ = last = f;
}
- x->x_last = last;
+ x->x_last = (PD_BIGORSMALL(last) ? 0. : last);
return (w + 5);
}
#endif