         snd        (* amp dist (line:kr 1 0 t))]
     src))
 
-(definst buzz [pitch 40 cutoff 300 dur 200]
+(definst overpad
+  [note 60 amp 0.7 attack 0.001 release 2]
+  (let [freq  (midicps note)
+        env   (env-gen (perc attack release) :action FREE)
+        f-env (+ freq (* 3 freq (env-gen (perc 0.012 (- release 0.1)))))
+        bfreq (/ freq 2)
+        sig   (apply +
+                     (concat (* 0.7 (sin-osc [bfreq (* 0.99 bfreq)]))
+                             (lpf (saw [freq (* freq 1.01)]) f-env)))
+        audio (* amp env sig)]
+    audio))
+
+(definst buzz
+  [pitch 40 cutoff 300 dur 200]
   (let [lpf-lev (* (+ 1 (lf-noise1:kr 10)) 400)
         a (lpf (saw (midicps pitch)) lpf-lev)
         b (sin-osc (midicps (- pitch 12)))
         env (env-gen 1 1 0 1 2 (perc 0.01 (/ dur 1000)))]
     (* env (+ a b))))
 
-(definst bass [freq 120 t 0.6 amp 0.5]
+(definst bass
+  [freq 120 t 0.6 amp 0.5]
   (let [env (env-gen (perc 0.08 t) :action FREE)
         src (saw [freq (* 0.98 freq) (* 2.015 freq)])
         src (clip2 (* 1.3 src) 0.8)

        zout (comb-n src :decaytime 4)]
    zout))

;(def alien-buffer (buffer 2250))
;(definst alien-computer [trig 0.3]
;  (ifft (pv-rand-comb (fft alien-buffer (white-noise))
;                               0.95 (impulse:kr trig))))))
;(defn buzzer [t tick dur notes]
;  (let [note (first notes)]
;    (if (> (rand) 0.9)
;      (do
;        (hit t :buzz :pitch note :dur dur)
;        (hit (+ t tick) :buzz :pitch note :dur dur)
;        (callback (+ t tick (- tick 100)) #'buzzer (+ t tick tick) tick dur (next notes)))
;      (do
;        (hit t :buzz :pitch note :dur dur)
;        (callback (+ t (- tick 100)) #'buzzer (+ t tick) tick dur (next notes))))))
;
;;(buzzer (+ (now) 200) 100 50 (cycle [68 80 48 80 92 75]))
;
;;; Helpers
;
;(defmacro mix [& args]
;  (syn (reduce (fn [mem arg] (list '+ mem arg))
;          args)))
;
;;; Toy synths... clean up eventually
;
;(def sin (synth sin {:out 0 :amp 0.1 :pitch 40 :dur 300}
;  (let [snd (sin-osc.ar (midicps :pitch))
;        env (env-gen.kr (linen 0.001 (/ :dur 1000.0) 0.002) :done-free)]
;    (out.ar :out (pan2.ar (* (* snd env) :amp) 0)))))
;
;(synth mouse-saw
;  (out.ar 0 (pan2.ar (sin-osc.ar (mouse-y.kr 10 1200 1 0) 0) 0)))
;
;(comment
;  (load-synth mouse-saw)
;  (hit mouse-saw)
;  )
;
;(synth noise-filter {:cutoff 500}
;  (quick (lpf.ar (* 0.4 (pink-noise.ar)) :cutoff)))


;(defn basic-sound []
;  (syn
;    (mul-add.ar
;      (decay2.ar (mul-add.ar
;                 (impulse.ar 8 0)
;                 (mul-add.kr (lf-saw.kr 0.3 0) -0.3 0.3)
;                 0)
;               0.001)
;      0.3 (+ (pulse.ar 80 0.3) (pulse.ar 81 0.3)))))
;
;(synth basic-synth
;  (quick (basic-sound)))
;
;(synth compressed-synth {:attack 0.01
;                            :release 0.01}
;  (let [z (basic-sound)]
;    (quick
;      (compander.ar z 0
;                    (mouse-x.kr 0.1 1) ; mouse controls gain
;                    1 0.5 ; slope below and above the knee
;                    :attack  ; clamp time (attack)
;                    :release)))) ; relax time (release)
;
;(defn wand [n]
;  (syn
;  (mix
;    (sin-osc.ar (mhz (- n octave)))
;    (lpf.ar (saw.ar [(mhz n) (mhz (+ n fifth))])
;          (mul-add.kr
;              (sin-osc.kr 4)
;              30
;              300)))))
;
;(synth triangle-test
;  (out.ar 0
;          (mul-add.ar
;            (wand 60)
;            (env-gen.kr 1 1 0 1 2 (triangle 3 0.8))
;            0)))
; TODO: Port the interesting ones to Overtone synthdefs

; SynthDef("vintage-bass", {|out=0, note=40, vel=0.5, gate=1|
;   var f = midicps(note);
;   var f2 = midicps(note-12);
;   var saw = Saw.ar([f, f], 0.075);
;   var saw2 = Saw.ar([f-2, f+1], 0.75);
;   var sq = Pulse.ar([f2, f2-1], 0.5, 0.3);
;   var snd = Mix([saw, saw2, sq], 0, 0.1);
;   var env = EnvGen.kr(Env.adsr(0.1, 3.3, 0.4, 0.3), gate, doneAction: 2);
;   var filt = env * MoogFF.ar(snd, env * vel * f+200, 2.2);
;   Out.ar(0, Pan2.ar(filt, 0))
; }).store;
; b = Synth("vintage-bass", ["note", 30.0, "vel", 0.6]);
; b.set("gate", 1);
; b.set("gate", 0);
;
; /////////////////////////////
; // Originally from the STK instrument models.  SuperCollider port found at lost URL.
;
; SynthDef(\flute, { arg out=0, gate=1, freq=440, amp=1.0, endReflection=0.5, jetReflection=0.5, jetRatio=0.32, noiseGain=0.15, vibFreq=5.925, vibGain=0.0, outputGain=1.0;
;
;   var nenv = EnvGen.ar(Env.linen(0.2, 0.03, 0.5, 0.5), gate, doneAction: 2);


; From the SC2 examples included with SC
; Don't think it's quite there, but almost...
(definst harmonic-swimming
  [amp 0.5]
  (let [freq     100
        partials 20
        z-init   0
