Set up a live coding looper for a guitar in live_audio

Hi all, I’d like to use with_fx :record in order to record a portion of a live_audio stream, let’s say 4 sec, and being able to playback that portion within a Live_loop and modifying it on the fly.
I have tried, with no success, to set it up but I am sure I am not getting something, possibly in relation with with_fx :record… Does anyone like to help me out? Is it even possible? Thnx in advance!


have a look at this script.

It is quite some time ago that I coded that so some clearing work will be needed - especially because the configuration is way to complicated. Also it provides 4 tracks and replay loops (and not just one so the loops will be dynamically created).

But it works and so it might be of some help for you.

I’ve done some stuff with this in the past, but with bass instead of guitar:

Code here:

Also code here:

Edit: Also make sure that your microphone has permissions if you’re using a mac:

Thank you both! I had a look at the code and wow!! I will study both. By the way, I am not using touch OSc and neither I am playing the guitar. What I am doing is live coding fx while my partner plays guitar. Hence I will need the simplest and quickest way to do it, on-the fly… But thank you both none the less. I will go through the code and workout something! I hope…