[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [sc-users] Event - extend or subclass?



actually, thanks to you!
i have been fiddling around with this after you mentioned it and it warmed my heart this christmas...
(routed to SimpleSynth)

m = MIDIOut(0, MIDIClient.destinations.at(0).uid);

p =     Pbind(
            \type, \midi,
            \midinote, Pfunc({r = 60.rand}, inf),
            \amp, Pfunc({1.0.rrand(0.5)}, inf),
            \chan, 0,
            \dur, 0.1,
            \sustain, 1,
            \midiout, m
    ).play;

d =  Pbind(
            \type, \midi,
            \midicmd, \noteOff,
            \midinote, Pfunc({r}, inf),
            \amp, Pfunc({1.0.rrand(0.5)}, inf),
            \chan, 0,
            \dur, 0.3.rand,
            \midiout, m
    ).play;

// send program changes
c =  Pbind(
            \type, \midi,
            \midicmd, \program,
            \progNum, Pfunc({128.rand}, inf),
            \amp, Pfunc({1.0.rrand(0.5)}, inf),
            \chan, 0,
            \dur, 0.01,
            \midiout, m
    ).play;
    
p.stop
d.stop
c.stop


cheerz,
tom


On 25 Dec 2005, at 21:54, ml13@xxxxxxxxxxxxx wrote:

Thanks to you too, ça marche...
kilian

Am 24.12.2005 um 23:48 schrieb tom tlalim:

e = Event.makeParentEvents.parentEvents.default.postcs
e.eventTypes[\midi].asCompileString

#{|server|
var freqs, lag, dur, sustain, strum;
var bndl, midiout, hasHate, midicmd;
...

hasHate = ~hasGate ? true// heh heh... naturally-born killer ;)

...
}


tom


On 24 Dec 2005, at 23:09, James Harkins wrote:

Event.default.eventTypes contains the actions that are taken for different \type values.

Event.default.eventTypes[\myNewEventType] = {
... action ...
};

hjh

On Dec 24, 2005, at 2:39 PM, ml13@xxxxxxxxxxxxx wrote:

Thats really cool! Now I am wondering what to do, if I wanted to add my own play behaviour, e.g. just postlining the midinote, or sending OSC to another server than scsynth maybe to do sample playback.

: H. James Harkins
.::!:.:.......:.::........:..!.::.::...:..:...:.:.:.:..:

"Come said the Muse,
Sing me a song no poet has yet chanted,
Sing me the universal."  -- Whitman

_______________________________________________
sc-users mailing list

..................................
www.tangiercluj.tk
..................................


_______________________________________________
sc-users mailing list

_______________________________________________
sc-users mailing list

..................................
..................................