Quantcast

waveset replace/inbetweening

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

waveset replace/inbetweening

marcin_p
hi List,

I'm searching for ways of combining wavestes with pulsar synthesis. I would be interested especially in finding a way to replace a chosen number of wavestes with pulsars. Has anyone done any work in this field?


e.g.

//wavesets

w = Wavesets.from("path to mono file");
(
Pbindef(\ws1).clear;
Pbindef(\ws1,
        \instrument, \wvst0,
        \startWs, Pn(Pseries(0, 1, 3000), 1),
        \numWs, 1,
        \playRate, 1,
        \bufnum, b.bufnum,
        \repeats, 1,
        \amp, 0.4,
        [\start, \length, \sustain], Pfunc({ |ev|
                var start, length, wsDur;

                #start, length, wsDur = w.frameFor(ev[\startWs], ev[\numWs]);
                [start, length, wsDur * ev[\repeats] / ev[\playRate].abs]
        }),
        \dur, Pkey(\sustain)
).play;
)

// Pulsar synthesis with client-side control
       
// a pulsaret and an envelope
a = Signal.sineFill(1024, 1/(1..10).scramble).putLast(0);
b = Env.perc.discretize(1024).putLast(0);
                // as buffers
x = Buffer.sendCollection(s, a, 1);
y = Buffer.sendCollection(s, b, 1);
// a pulsar synthdef
(
SynthDef(\pulsar1, {|out, wavebuf, envbuf, form=200, amp=0.2, pan|
        var grDur =  1/form;
        var pulsaret = Osc1.ar(wavebuf, grDur);
        var env = Osc1.ar(envbuf, grDur, doneAction: 2);
       
        OffsetOut.ar(out, Pan2.ar(pulsaret * env, pan, amp));
}, \ir ! 6).add;
)
Synth(\pulsar1, [\wavebuf, x, \envbuf, y]);

        // a simple pattern
(
Pbindef(\pulsar1,
                \instrument, \pulsar1,
                \wavebuf, x, \envbuf, y,
                \form, Pn(Penv([20, 1200], [4], \exp)).loop,
                \amp, 0.2, \pan, 0,
                \fund, 12,
                \dur, Pfunc({ |ev| ev.fund.reciprocal })
).play;
)

What would be a way of combining these two patterns?

cheers

marcin

 
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: waveset replace/inbetweening

daniel-mayer


Am 22.02.2017 um 18:09 schrieb marcin_p <[hidden email]>:

> hi List,
>
> I'm searching for ways of combining wavestes with pulsar synthesis. I would
> be interested especially in finding a way to replace a chosen number of
> wavestes with pulsars. Has anyone done any work in this field?


I haven't, it sounds like a nice idea.
Just had some fun with Pswitch1:

( \wvst0 from SC Book examples )

(
x = Pswitch1(
        [Pbindef(\ws1), Pbindef(\pulsar1)],
        Pstutter(Pdefn(\rep, Pwhite(1, 10)), Pseq([0, 1], inf))
).play
)

Pbindef(\ws1, \numWs, 10)

Pdefn(\rep, 1)

Pbindef(\pulsar1, \fund, 100)

Pdefn(\rep, 5)

Pbindef(\pulsar1, \fund, Pseg(Pseq([50, 500], inf), Pwhite(0.5, 3)))

Pbindef(\ws1, \numWs, Pwhite(1, 60))

x.stop


Extension: more patterns to switch between etc.
And as always: Pspawner is a good option for pattern meta control.


Regards

Daniel

-----------------------------
www.daniel-mayer.at
-----------------------------


_______________________________________________
sc-users mailing list

info (subscription, etc.): http://www.birmingham.ac.uk/facilities/ea-studios/research/supercollider/mailinglist.aspx
archive: http://www.listarc.bham.ac.uk/marchives/sc-users/
search: http://www.listarc.bham.ac.uk/lists/sc-users/search/
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: waveset replace/inbetweening

marcin_p
this is great Daniel,

going to play with it a bit and will post some examples here

best,

marcin  
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: waveset replace/inbetweening

marcin_p
hi Daniel,

had a great time playing with the example you have suggested.

I'm trying to achieve the inbetweening within one Ndef definition (without using patterns): to have sort of a hybrid between pulsar and wavesets. At the moment I'm considering using demand rate Dswitch/Dswitch1 - would you suggest any other solution?

best,

marcin  
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: waveset replace/inbetweening

daniel-mayer
In reply to this post by marcin_p

>hi Daniel,

>had a great time playing with the example you have suggested.

>I'm trying to achieve the inbetweening within one Ndef definition (without using patterns): 
>to have sort of a hybrid between pulsar and wavesets. 
>At the moment I'm considering using demand rate Dswitch/Dswitch1 - 
>would you suggest any other solution?

>best,
>marcin  


A demand rate approach would certainly be possible, I suppose it will be much harder to implement.

First I'd start with building a setup for playing wavesets with drate ugens only and add switching to pulsars in a second step. Already this reduction could raise tricky problems.

I'haven't seen any examples - has someone tried that ?

I'd implement the waveset player and the trigger with two synthdefs, the player could get values of start, length, sustain and the trigger for phasor and envelope from buses, that way microrhythms could be flexibly exchanged by connecting different drate trigger synths (I'd want to have the same flexibility as with patterns). But then these synths would have to get analysis data from language also. Further the switching to pulsars would have to be implemented, maybe into the waveset player.

The overhead could pay if you are concentrating on very short wavesets and/or need OSC bandwith for other stuff.

Regards

Daniel

-----------------------------
www.daniel-mayer.at
-----------------------------

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: waveset replace/inbetweening

daniel-mayer


Am 20.05.2017 um 15:41 schrieb [hidden email]:

> A demand rate approach would certainly be possible, I suppose it will be much harder to implement.

> I'd implement the waveset player and the trigger with two synthdefs, the player could get values of start, length, sustain and the trigger for phasor and envelope from buses, that way microrhythms could be flexibly exchanged by connecting different drate trigger synths (I'd want to have the same flexibility as with patterns). But then these synths would have to get analysis data from language also.


Well, actually that's not necessary: we can load w.fracXings and w.fracLengths into buffers.
Then an equivalent to w.frameFor can easily be calculated server-side and the result (start, length, sustain)
can be taken over by phasor and envelope (either directly within one synth or via buses as suggested).

Greetings

Daniel

-----------------------------
www.daniel-mayer.at
-----------------------------


_______________________________________________
sc-users mailing list

info (subscription, etc.): http://www.birmingham.ac.uk/facilities/ea-studios/research/supercollider/mailinglist.aspx
archive: http://www.listarc.bham.ac.uk/marchives/sc-users/
search: http://www.listarc.bham.ac.uk/lists/sc-users/search/
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: waveset replace/inbetweening

daniel-mayer


Am 20.05.2017 um 22:48 schrieb [hidden email]:

>
>
> Am 20.05.2017 um 15:41 schrieb [hidden email]:
>
>> A demand rate approach would certainly be possible, I suppose it will be much harder to implement.
>
>> I'd implement the waveset player and the trigger with two synthdefs, the player could get values of start, length, sustain and the trigger for phasor and envelope from buses, that way microrhythms could be flexibly exchanged by connecting different drate trigger synths (I'd want to have the same flexibility as with patterns). But then these synths would have to get analysis data from language also.
>
>
> Well, actually that's not necessary: we can load w.fracXings and w.fracLengths into buffers.
> Then an equivalent to w.frameFor can easily be calculated server-side and the result (start, length, sustain)
> can be taken over by phasor and envelope (either directly within one synth or via buses as suggested).


... hm, ok that *should* somehow be possible, but my previous prediction of demand rate quirks has just become true.
I was trying to poll xing indices and use polled indices for duty lengths - but ATM I have no idea how to write that ...
if someone tried to control wavesets playback with drate ugens please let us know.

@Alberto, did you ?

Regards

Daniel

-----------------------------
www.daniel-mayer.at
-----------------------------
_______________________________________________
sc-users mailing list

info (subscription, etc.): http://www.birmingham.ac.uk/facilities/ea-studios/research/supercollider/mailinglist.aspx
archive: http://www.listarc.bham.ac.uk/marchives/sc-users/
search: http://www.listarc.bham.ac.uk/lists/sc-users/search/
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: waveset replace/inbetweening

alberto.decampo
Hi Daniel,

> On 21/05/2017, at 02:15 , [hidden email] wrote:
>
>
>
> Am 20.05.2017 um 22:48 schrieb [hidden email]:
>
>>
>>
>> Am 20.05.2017 um 15:41 schrieb [hidden email]:
>>
>>> A demand rate approach would certainly be possible, I suppose it will be much harder to implement.
>>
>>> I'd implement the waveset player and the trigger with two synthdefs, the player could get values of start, length, sustain and the trigger for phasor and envelope from buses, that way microrhythms could be flexibly exchanged by connecting different drate trigger synths (I'd want to have the same flexibility as with patterns). But then these synths would have to get analysis data from language also.
>>
>>
>> Well, actually that's not necessary: we can load w.fracXings and w.fracLengths into buffers.
>> Then an equivalent to w.frameFor can easily be calculated server-side and the result (start, length, sustain)
>> can be taken over by phasor and envelope (either directly within one synth or via buses as suggested).
>
>
> ... hm, ok that *should* somehow be possible, but my previous prediction of demand rate quirks has just become true.
> I was trying to poll xing indices and use polled indices for duty lengths - but ATM I have no idea how to write that ...
> if someone tried to control wavesets playback with drate ugens please let us know.
>
> @Alberto, did you ?

no not yet :-)
I agree that it should be possible.
Probably best to create dr, ar, kr equivalents of frameFor etc,
which get bufnums as inputs for xings, lengths and amps,
and create proper control streams for a phasor that plays the waveset stream.

best adc
_______________________________________________
sc-users mailing list

info (subscription, etc.): http://www.birmingham.ac.uk/facilities/ea-studios/research/supercollider/mailinglist.aspx
archive: http://www.listarc.bham.ac.uk/marchives/sc-users/
search: http://www.listarc.bham.ac.uk/lists/sc-users/search/
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: waveset replace/inbetweening

marcin_p
thanks Daniel and Alberto, very useful points. I'll be trying to work along these suggestions in the next couple of days.

best 

Marcin


On Sun, 21 May 2017 at 12:49, [hidden email]
Hi Daniel,

> On 21/05/2017, at 02:15 , [hidden email] wrote:
>
>
>
> Am 20.05.2017 um 22:48 schrieb [hidden email]:
>
>>
>>
>> Am 20.05.2017 um 15:41 schrieb [hidden email]:
>>
>>> A demand rate approach would certainly be possible, I suppose it will be much harder to implement.
>>
>>> I'd implement the waveset player and the trigger with two synthdefs, the player could get values of start, length, sustain and the trigger for phasor and envelope from buses, that way microrhythms could be flexibly exchanged by connecting different drate trigger synths (I'd want to have the same flexibility as with patterns). But then these synths would have to get analysis data from language also.
>>
>>
>> Well, actually that's not necessary: we can load w.fracXings and w.fracLengths into buffers.
>> Then an equivalent to w.frameFor can easily be calculated server-side and the result (start, length, sustain)
>> can be taken over by phasor and envelope (either directly within one synth or via buses as suggested).
>
>
> ... hm, ok that *should* somehow be possible, but my previous prediction of demand rate quirks has just become true.
> I was trying to poll xing indices and use polled indices for duty lengths - but ATM I have no idea how to write that ...
> if someone tried to control wavesets playback with drate ugens please let us know.
>
> @Alberto, did you ?

no not yet :-)
I agree that it should be possible.
Probably best to create dr, ar, kr equivalents of frameFor etc,
which get bufnums as inputs for xings, lengths and amps,
and create proper control streams for a phasor that plays the waveset stream.

best adc
Loading...