View this PageEdit this PageUploads to this PageHistory of this PageTop of the SwikiRecent ChangesSearch the SwikiHelp Guide

Pfbind: a modified FilterPattern



Pfbind: an different version of Pbindf: Pfbind.hqx
(now with test file.)






old versions:



Pbindf2.sc a filter pattern, that overrides its parents
Pbindf3.sc a filter pattern, that overrides its parents, unless the child yields \no.




from the mail...
[...]

Julian Rohrhuber wrote:

why is it not possible to partly override values in a Pbind?
I've been looking through the source, but I can't find the reason
why it shouldn't work like the following:

(
{
a = Pbind(\degree, Pseq([0, 1, 2], inf));
a = Pbindf(\degree, 5, a);
a.ar(2)

}.play;
)

(
{
a = Pbind(\degree, Pseq([0, 1, 2], inf));
a = Pmul(\degree, 2, a);
a.ar(2)

}.play;
)


::crucial-systems.com:: wrote:

yes, i still stubbornly maintain that it is backwards.
in the source, it inserts into the
event.put(\name,stream.next)

and THEN sends it to the filtered pattern.

imho it should read off the page the same as an audio filter:

Pbindf(\degree,5,
Pbind(\degree, Pseq([0, 1, 2], inf)
);

the outer thing happens after the inner thing, and acts upon its
output.

LPF.ar(input,ffreq)


its easily rewired, and i attempt to attach it, excite@&^%$#!willing






Julian Rohrhuber wrote:


> I don't know what you mean by gaps in the stream.
> You can of course return any symbol you want to.

if I have a Pbind, it is overriding values in the underlying Event:

Pbind(
\degree, Pseq([1, 4, 5])
)

say if i want to leave the default value of the passed down event unchanged,
I'd then write something like

Pbind(
\degree, Pseq([1, 4, \no, 5])
)

furthermore, if I use Pbindf (Pbindf2 that felix posted)
to modify that stream again, I could use \no to leave 'gaps'(unmodified
values) again.

it is similar to the behaviour of Pen, I'd say.






attached one version of Pbindf, Pbindf3 in fact,
that works like that. Wouldn't that be a good standard
behaviour for Pbindf?

usage:

a = Pbind.new;
a = Pbindf3(\degree, Pseq([5, 6, \no, 4, \no], inf), a);
a = Pbindf3(\degree, Pseq([1, 1, \no, \no], inf), a);

b = a.asEventStream(Event.protoEvent);
5.do({ b.next.at(\degree).postln });






James then commented that he would switch sc3 to the audio filters paradigm. ie. it would override any patterns 'within'/below.



feel free to contribute
back to sc






Links to this Page