Not fully played \phrase pattern

In this \phrase type pattern, the repeated pattern plays only for ±80% of its duration. And I don’t understand why. I have tried to reduce it to its smaller expression. It keeps playing only 81,25% of the expected time.

Pdef(\arp1, { |notes, pattern, dur|
	// var pt=pattern.asStream.debug("pattern");  // 1
	var pt=pattern.value.debug("pattern.value"); // 2
	var i=1;

	// Pfindur(dur.value,

		// \idx,Pfunc{"idx: ")}, // 1
			\idx,pt , // 2
		\note,Pindex(notes.value,Pkey(\idx).clip(0,notes.value.size-1))/*.poll("note: ")*/,
		\debug, Pfunc({|e| format("%) idx: %",i,e[\idx]).postln; i=i+1}),
// ) 

		\type, \phrase,
		\instrument, \arp1,
		\dur, 8,
		\notes, Pseq([`[0,4,7,10],`[5,9,12,15]],2),
		// \pattern, Pfunc{Pseq([0,1,2,3,2,3,1,2],inf)}, // 1+2
		\pattern, Pfunc{Pn(0,inf)}, // 1+2

I guess I have a misconception issue somewhere, but can’t find it…

Phrases are clipped to the \sustain duration of the event that generated them - they should play exactly as long as the original event would have. The default event has a legato of 0.8, which means it’s sustain is 80% of it’s duration, which is why your phrases are being cut off. Set your \legato to 1.0 to have the phrase fill the entire duration (you can go longer as well, to have overlapping phrases).

1 Like