overtone

diego.videco 2023-12-11T14:58:56.986969Z

Is anyone planning on performing? https://solstice.toplap.org/

diego.videco 2023-12-11T15:00:02.971719Z

Join the solstice stream! There’s a 36 hour live online stream happening on 21/22 December UTC, to celebrate the solstice and the dawning of a new cycle. Please get involved by contributing a 15 minute live performance! All live coders welcome, especially new people - this is a great opportunity for your first live gig! There are no constraints on what or how you perform, as long as live coding is involved (e.g. it doesn’t have to be from-scratch live coding, working with pre-prepared code is totally fine!). You can reserve a 15 minute slot here (times should appear in your own timezone): https://solstice.toplap.org/ You’ll then get instructions for testing and streaming in your email, which you can have a sneak peak at here: https://docs.google.com/document/d/1DQLdSvNal03mH21w0K6vBJoL96XPshUi-ZHyA2vCLhw/edit#heading=h.csu18y68777e You can watch the performances from last year’s solstice stream on youtube: https://www.youtube.com/playlist?list=PLMBIpibV-wQIdS6D1vdijRZPfLBrRP9A_) or http://archive.org: https://archive.org/details/toplap?sort=-date

👏 2
plexus 2023-12-11T16:12:57.110549Z

Maybe next year 🙂 I hope to finally finish something musically sounding during the christmas/new year break

👍 2
diego.videco 2023-12-11T19:27:08.123429Z

If anyone likes using Ndef, here’s a very basic pseudo-implementation of the SuperCollider class. I think covers around 70%-80% of use-cases of Ndef, but there’s definitely many things missing. I use it a lot for developing synths, and for that it works great.

(ns tieminos.sc-utils.ndef.v1
  "A basic Ndef implementation"
  (:require
   [overtone.core :as o]))

(defonce ndefs (atom {}))

(defmacro ndef
  [id synth & {:keys [out fade-time]
               :or {out 0 fade-time 3}}]
  `(let [synth# ((o/synth
                   [~(symbol "gate") 1]
                  (o/out ~out
                         (~(symbol "*") (o/env-gen
                                (o/asr ~fade-time 1 ~fade-time)
                                :gate ~(symbol "gate")
                                :action o/FREE)
                               ~synth))))]

     (when-let [prev-synth# (get @ndefs ~id)]
       (try (o/ctl prev-synth# :gate 0)
            (catch Exception ~(symbol "_e") nil)))
     (swap! ndefs assoc ~id synth#)))

(defn stop [& ids]
  (doseq [id ids]
    (when-let [prev-synth (get @ndefs id)]
      (try (o/ctl prev-synth :gate 0)
           (catch Exception _e nil))
      (swap! ndefs dissoc id))))

(comment
  (do
    (reset! ndefs {})
    (macroexpand-1
      '(ndef :my-id (* 0.2 (o/sin-osc 200)) {:out 0})))

  (ndef :my-id (* 0.2 (o/sin-osc 100)))
  (stop :my-id)
  (o/stop))

diego.videco 2023-12-11T19:28:56.551269Z

basically it allows the user to cross-fade between synth definitions, that’s why it’s cool for developing synths. Better than o/demo imho, as it can also be used for performance.

plexus 2023-12-12T10:03:21.944859Z

Interesting! There's so much in SC I'm still unfamiliar with. I perused the implementation of ndef/proxyspace and it looks like it works by allocating busses and changing/fading what goes into the bus (I think). Should be doable to do something similar on our side.

diego.videco 2023-12-12T15:52:21.050369Z

yeah, the audio routing is interesting in that implementation as it allows to more freely route the signals. That’s still uncovered in what I did, which is just about fading in and out synths