 (ns klangmeister.synthesis)
+
+; Plumbing
+
+(defn destination [context at duration]
+  (.-destination context))
 
 (defn plug [param input context at duration]
   "Plug an input into an audio parameter,

(defn percussive [attack decay]
  (line [attack 1.0] [decay 0.0]))

(defn connect
  [ugen1 ugen2]
  (fn [context at duration]

  (fn [context at duration]
    (doto (.createGain context)
      (-> .-gain (plug level context at duration)))))


; Envelopes

(defn line
  "Build a line out of [dx y] coordinates, starting at [0 0]."
