How I can use USB-mic in Overtone? Here is an example to use regular 3.5mm microphone:
(ns insane-noises.vocoder)
(use 'overtone.live)
(def a (buffer 2048))
(def b (buffer 2048))
(demo 5
(let [input (sound-in 0); mic
src (white-noise) ; synth - try replacing this with other sound sources
formed (pv-mul (fft a input) (fft b src))
audio (ifft formed)]
(pan2 (* 0.1 audio))))
When I try in (sound-in 0) change 0 to 1, 2, 3... - nothing works. My mic works good in all applications like skype etc.
I've just tried to reproduce it. It works only intermittently. I ran
in the REPL, allowing me to see the OSC communication between Overtone and SuperCollider.
It fails in two different ways depending on whether I'm using overtone.core and connecting to an external server, or using overtone.live.
With overtone.live, I allocate the buffers just fine, but when I run the demo function, I get:
... followed by a bunch of events related to Overtone cleaning up its default nodes and groups and such as part of shutting down. If you don't get the same output from your overtone.live, I'll know I have something to troubleshoot about my JACK settings or something.
Using overtone.core connected to an external server, it works intermittently.
When it works, I get the following events:
When it fails, I get these:
This looks like a malfunction in the OSC communication with the server -- somewhere the node ID isn't getting incremented correctly.
What do you get in terms of events when you try?