fixing mega bugs introduced with audio click and another hidden regarding starts in ppar

main
mwinter 1 year ago
parent 101fae842c
commit 87fafc8599

@ -272,7 +272,7 @@ s.waitForBoot({
//\dur, Pseq(8.collect({arg i; 1}) ++ transportData.collect({arg item; item[2]}), 1),
\measure, Pseq(8.collect({arg i; 2}) ++ transportData.collect({arg item; item[0]}) - 1, 1),
\beat, Pseq(8.collect({arg i; 2}) ++ transportData.collect({arg item; item[1]}) - 1, 1),
\dur, Pseq(transportData.collect({arg item; item[2]}), 1),
\dur, Pseq(8.collect({arg i; 1}) ++ transportData.collect({arg item; item[2]}), 1),
\sustain, 0.75,
\primaryBufNum, clickBufPrimary,
\secondaryBufNum, clickBufSecondary,
@ -299,7 +299,7 @@ s.waitForBoot({
s.sync(c);
createTransportData = {arg measureLengths;
measureLengths.collect({arg dur, measure;
measureLengths.postln.collect({arg dur, measure;
var beats;
if(dur.round(0.5) % 1 == 0, {
dur.asInteger.collect({arg beat;
@ -308,6 +308,7 @@ s.waitForBoot({
}, {
var eigths, beatDurs;
eigths = (dur / 0.5).round(0.5).asInteger;
/*
beatDurs = case
{eigths <= 3} {[dur]}
{eigths == 5} {[1, 1.5]}
@ -316,12 +317,14 @@ s.waitForBoot({
{eigths == 11} {[1, 1, 1, 1, 1.5]}
{eigths == 13} {[1, 1, 1, 1, 1, 1.5]}
{eigths == 15} {[1, 1, 1, 1, 1, 1, 1.5]};
*/
beatDurs = eigths.collect({0.5});
beatDurs.collect({arg bDur, beat;
[measure + 1, beat + 1, bDur]
})
});
}).flatten;
}).flatten.postln;
};
createTransportPattern = {arg addr, transportData;
@ -395,7 +398,7 @@ s.waitForBoot({
var pbinds, transportData, measureLengths, patterns, stream, offset, offsetStream, terminationStream;
# pbinds, transportData, measureLengths = playbackData[msg[2]];
//patterns = Ppar(pbinds.postln.add(createTransportPattern.value(addr, transportData).postln));
patterns = Ptpar([0, createTransportPattern.value(addr, transportData), 1 * msg[5]/60.0, createClickPattern.value(transportData, group), 9 * msg[5]/60.0, Ppar(pbinds)]);
patterns = Ptpar([0, createTransportPattern.value(addr, transportData), 1 * msg[5]/60.0, createClickPattern.value(transportData, group), 8 + (msg[5]/60.0), Ppar(pbinds)]);
stream = patterns.asStream;
if(msg[3] == 1, {

Loading…
Cancel
Save