Hello Synths,
I am trying to build my first live coding set and finding some issues. I am building a music with tempo = 64bpm, 3/4, and which is completely within the quadrature of 16 bars (48 beats). The main problem is that I would like to set a Quant which allows me to trigger patterns that starts on the next quadrature, independently of where I am in time grid. I have tried to build the following metronome, which visually seems to work. When I trigger the patterns
(
t = TempoClock.new((64)/60);
t.schedAbs(t.nextBar, {t.beatsPerBar_(3)});
~postBeat = {postcs(["quadrature---------------",t.beats.div(16*3)]);1; postcs(["beats---------",t.beats]);1; postcs(["bar",t.bar]); 1;};
t.schedAbs(t.nextBar, {~postBeat.value});
)
Pdef(\fl).play(t, quant:4.0)
Pdef(\fl).play(t, quant:(48- (((t.beats - (t.beats.div(48) * 48))**2).sqrt)).round )
Pdef(\fl, Pbind(\instrument, \fl, \type, \midi, \midiout, ~b2, \db, -3, \degree, Pseq((1..48), inf) ,\dur, 1))
Apparently, the quadrature quantization seems to work visually when I post it:
((48- (((t.beats - (t.beats.div(48) * 48))**2).sqrt)).round).postln
But when I try it within the Pdef it does not work⦠What Is going on?
Any easier idea about how to do this ? Are there any quarks for this ? Specially one that allows me to see the time grid and the patterns there?