 (def square (partial oscillator "square"))
 (def triangle (partial oscillator "triangle"))
 
+
+; Filters
+
 (defn biquad-filter [type freq]
   (fn [context at duration]
     (doto (.createBiquadFilter context)

        (.start at)))))

(def white-noise (partial noise #(-> (js/Math.random) (* 2.0) dec)))

(defn oscillator
  ([type freq detune]

  (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]."
