Mercurial > hg > dmlib
diff jssplr.c @ 155:2862f1571250
Use dmClamp().
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Sat, 06 Oct 2012 05:17:54 +0300 |
parents | 969cefb2f8c3 |
children | 4727db27e85d |
line wrap: on
line diff
--- a/jssplr.c Sat Oct 06 04:44:26 2012 +0300 +++ b/jssplr.c Sat Oct 06 05:17:54 2012 +0300 @@ -1244,10 +1244,6 @@ // Compute new pitch tmp = dmClamp(chn->iCNote + inst->ERelNote, 0, 119); //fprintf(stderr, "HEH: %d + %d = %d\n", chn->iCNote, inst->ERelNote, tmp); - if (tmp < 0) - tmp = 0; - else if (tmp > 119) - tmp = 119; chn->iCPitch = jmpGetPeriodFromNote(mp, tmp, inst->EFineTune); JMPSETNDFLAGS(cdfNewPitch);