diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/SoftClipperGen.ck | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/SoftClipperGen.ck b/lib/SoftClipperGen.ck new file mode 100644 index 0000000..9969cd8 --- /dev/null +++ b/lib/SoftClipperGen.ck @@ -0,0 +1,10 @@ +/* + * soft-clip a signal within -1 to 1 using a Ghugen + */ +public class SoftClipper extends Chugen { + fun float + tick(float in) + { + return Math.atan(in*2)/(Math.PI/2); + } +} |