Mercurial > hg > dmlib
diff src/dmcurves.h @ 980:43594ac98f91
Move dmClamp*() functions back to dmlib.h
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Fri, 27 Feb 2015 16:25:02 +0200 |
parents | 1b439304ff3c |
children | 7df95aefb9c6 |
line wrap: on
line diff
--- a/src/dmcurves.h Fri Feb 27 16:24:42 2015 +0200 +++ b/src/dmcurves.h Fri Feb 27 16:25:02 2015 +0200 @@ -29,18 +29,6 @@ DMFloat dmCatmullRom(const DMFloat t, const DMFloat p0, const DMFloat p1, const DMFloat p2, const DMFloat p3); -static inline DMFloat dmClamp10(const DMFloat a) -{ - return (a < 0.0f ? 0.0f : (a > 1.0f ? 1.0f : a)); -} - - -static inline int dmClamp(const int v, const int min, const int max) -{ - return (v < min ? min : (v > max ? max : v)); -} - - static inline DMFloat dmLerpSCurve(DMLerpContext *ctx, const DMFloat step) { const DMFloat n = step / ctx->nsteps;