BufPlayBungee

Hello all! I wrote a quick and dirty implementation for the bungee timestretching library. It’s dirty because it still allocates on the audio thread (i was thinking of just allocating on a re-entering thread and swap, but don’t have time atm), but apart that it’s really fun to use.

https://github.com/aleksandarkoruga/BufPlayBungee

There’s also a compiled version for win in: public-extensions/BufPlayBungee at main · aleksandarkoruga/public-extensions · GitHub

4 Likes

Hey there just built for macOS. Server immediately crashes if I change speed param!

(
a = Buffer.readChannel(s, "file/path", channels: [0]);

    {
        var sig;
        var pos = Phasor.ar(0, BufRateScale.kr(a) / BufFrames.kr(a), 0, 1);
        sig = BufPlayBungee.ar(a, speed: 1, pitch: 1.0, position: pos, trigPos: 0);
        sig;
    }.play;
)

I’m not him, but I tested the ugen as well and what I understood about it’s usage is that the position is ‘sampled’ upon trigger from the trigPos. The position would then be normalized internally between 0-1.
This works for me:

(
b = Buffer.read(s, ExampleFiles.child);

    {
    var sig;
	var trig = Dust.kr(2) ! 4;
	
	sig = BufPlayBungee.ar(b,
		speed: {2.0.exprand(0.01)}!4,
		pitch: 0.9,
		position: TRand.kr(0,1,trig), 
		trigPos: trig
	);
	sig = Pan2.ar(sig,TChoose.kr(trig, [-1,1]));
	sig;    
}.play;
)