parallel pattern and OSC to visuals
parent
1274cc4e0d
commit
9f9e731a75
|
@ -21,62 +21,57 @@ Pdef(\m_2, Pbind( \type, \midi, \midicmd, \noteOn, \midiout, ~m32_2)).play(quan
|
|||
// CC Control Message 1 ---> BOTTOM Mother32 ASSIGN OUT
|
||||
Pdef(\m_2_CC, Pbind( \type, \midi, \midicmd, \control, \midiout, ~m32_2, \ctlNum, 1, \control, Pexprand(77,127, inf), \dur, 1/8 )).play(quant:4);
|
||||
|
||||
|
||||
///////////////////////////////////
|
||||
//Pdef(\processing, Pfunc { ~host.sendMsg("/sc3p5", rrand(1,256).asFloat);}).play(quant: 4);
|
||||
|
||||
Pdef(\processing, Pfunc { ~host.sendMsg("/sc3p5", rrand(1,256).asFloat);}).play(quant: 4);
|
||||
//~host.sendMsg("/sc3p5", rrand(1,256).asFloat);
|
||||
|
||||
~host.sendMsg("/sc3p5", rrand(1,256).asFloat);
|
||||
//https://sc-users.bham.ac.narkive.com/75iSw2f6/sending-osc-commands-instead-of-trigger-synths-with-patterns
|
||||
|
||||
https://sc-users.bham.ac.narkive.com/75iSw2f6/sending-osc-commands-instead-of-trigger-synths-with-patterns
|
||||
n = NetAddr("127.0.0.1", 47120);
|
||||
|
||||
n=NetAddr("127.0.0.1", 47120);
|
||||
{50.do {n.sendMsg("/test",200.rand,200.rand);0.2.wait;}}.fork;
|
||||
//{50.do {n.sendMsg("/test",200.rand,200.rand);0.2.wait;}}.fork;
|
||||
|
||||
(
|
||||
( Event.addEventType(\processingOSC, { | server |
|
||||
var processingOscServer = NetAddr("192.168.178.166", 47120);
|
||||
//var processingOscServer = NetAddr("127.0.0.1", 47120);
|
||||
var notes = [~degree.value, ~ctranspose.value, ~velocity.value,
|
||||
~sustain.value, ~lag.value, ~timingOffset.value].flop;
|
||||
|
||||
Event.addEventType(\processingOSC, { | server |
|
||||
var processingOscServer = NetAddr("192.168.178.166", 47120);
|
||||
//var processingOscServer = NetAddr("127.0.0.1", 47120);
|
||||
var notes = [~midinote.value, ~ctranspose.value, ~velocity.value,
|
||||
~sustain.value, ~lag.value, ~timingOffset.value].flop;
|
||||
var bndl;
|
||||
var timeNoteOn, timeNoteOff;
|
||||
|
||||
var bndl;
|
||||
var timeNoteOn, timeNoteOff;
|
||||
//processingOscServer.sendMsg("/test",200.rand,200.rand);
|
||||
//processingOscServer.sendMsg("/sc3p5",200.rand, 200.rand);
|
||||
|
||||
//processingOscServer.sendMsg("/test",200.rand,200.rand);
|
||||
//processingOscServer.sendMsg("/sc3p5",200.rand, 200.rand);
|
||||
// n.sendMsg("/sc3p5", i.asFloat); // send OSC message to P5
|
||||
notes.do {|note|
|
||||
processingOscServer.sendMsg("/mother1", 1920.rand);
|
||||
processingOscServer.sendMsg("/mother2", 1080.rand);
|
||||
//processingOscServer.sendMsg("/sc3p5", rrand(1,256).asFloat);
|
||||
notes.do {|note|
|
||||
processingOscServer.sendMsg("/sc3p5", note[0].asFloat); // send OSC message to P5
|
||||
processingOscServer.sendMsg("/mother2", note[1].asFloat); // send OSC message to P5
|
||||
|
||||
// sustain and timingOffset are in beats, lag is in seconds
|
||||
//timeNoteOn = (thisThread.clock.tempo.reciprocal*note[5])+note[4];
|
||||
//timeNoteOff =
|
||||
//(thisThread.clock.tempo.reciprocal*(note[3]+note[5]))+note[4];
|
||||
//{processingOscServer.sendMsg("/renoise/trigger/note_on", -1, -1,
|
||||
//(note[0]+note[1]).asInt, note[2].asInt)}.defer(timeNoteOn);
|
||||
//{processingOscServer.sendMsg("/renoise/trigger/note_off", -1, -1,
|
||||
//(note[0]+note[1]).asInt)}.defer(timeNoteOff);
|
||||
}
|
||||
//processingOscServer.sendMsg("/mother1", 1920.rand);
|
||||
//processingOscServer.sendMsg("/mother2", 1080.rand);
|
||||
//processingOscServer.sendMsg("/sc3p5", rrand(1,256).asFloat);
|
||||
|
||||
// sustain and timingOffset are in beats, lag is in seconds
|
||||
//timeNoteOn = (thisThread.clock.tempo.reciprocal*note[5])+note[4];
|
||||
//timeNoteOff =
|
||||
//(thisThread.clock.tempo.reciprocal*(note[3]+note[5]))+note[4];
|
||||
//{processingOscServer.sendMsg("/renoise/trigger/note_on", -1, -1,
|
||||
//(note[0]+note[1]).asInt, note[2].asInt)}.defer(timeNoteOn);
|
||||
//{processingOscServer.sendMsg("/renoise/trigger/note_off", -1, -1,
|
||||
//(note[0]+note[1]).asInt)}.defer(timeNoteOff);
|
||||
}
|
||||
});
|
||||
)
|
||||
|
||||
( Pdef(\processingA, Pbind(*[ type: \processingOSC,
|
||||
dur: 1/8, degree: [2,5,12], ]); ))
|
||||
dur: 1/8, degree: Pseq([2,5,12,200,600,900,1000], inf), ]); ))
|
||||
|
||||
( Pdef(\processingB, Pbind(*[ type: \processingOSC,
|
||||
dur: 1/8, degree: [2,5,12], ]); ))
|
||||
|
||||
dur: 1/8, ctranspose: Pseq([2,5,12,300,600,900], inf), ]); ))
|
||||
|
||||
Pdef(\processingA).play(quant: 4); // TOP MOTHER
|
||||
Pdef(\processingA).stop;
|
||||
Pdef(\processingB).play(quant: 4); // TOP MOTHER
|
||||
Pdef(\processingB).stop;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -5,6 +5,10 @@
|
|||
|
||||
TempoClock.default.tempo = 60/60;
|
||||
|
||||
TempoClock.default.tempo = 30/60;
|
||||
|
||||
|
||||
|
||||
~rx0 = Pwrand([1/8, 1/4, 1/2, 4],[80,50,20,20].normalizeSum, 1);
|
||||
~rx1 = Pwrand([1/8, 1/4, 1/2, 1],[80,50,20,20].normalizeSum, 1);
|
||||
~rx2 = Pwrand([1/8, 1/4, 1/2],[80,50,20].normalizeSum, 1);
|
||||
|
@ -60,7 +64,7 @@ TempoClock.default.tempo = 60/60;
|
|||
~s4 = Scale.chromatic;
|
||||
|
||||
~bassroot = Pseq([0,4,2,3,1,4, 0],1);
|
||||
~bassroot16 = Pdup(32, Pseq([0,4,2,3,1, 4,0],inf));
|
||||
~bassroot16 = Pdup(32, Pseq([0,4,2,3,1, 4,0],1));
|
||||
|
||||
|
||||
~d0 = Pxrand([0,2,4,6],32);
|
||||
|
@ -77,14 +81,93 @@ TempoClock.default.tempo = 60/60;
|
|||
Pn( ~d1, 1),
|
||||
Pn( ~d4, 1),
|
||||
Pn( ~d0, 1),
|
||||
], inf);
|
||||
], 1);
|
||||
|
||||
Pbindef(\m_2, \octave, ~o1);
|
||||
Pbindef(\m_2, \degree, ~bassroot16);
|
||||
|
||||
n = NetAddr("192.168.178.166", 47120);
|
||||
n.sendMsg("/mother1", 200.rand.asFloat );
|
||||
|
||||
// e harmonic minor
|
||||
Pbindef(\m_1, \root, 4, \scale,~s0,\degree,~dseq,\octave, ~o3,\dur,~rs );
|
||||
Pbindef(\m_2, \root, 4, \scale,~s0,\degree, ~bassroot16,\octave, ~o1, \dur, ~rb );
|
||||
|
||||
Pbindef(\m_1, \root, 4, \scale,~s2, \degree, ~dseq, \octave, ~o1, \dur,~rb,
|
||||
\p5, Pfunc { |e| n.sendMsg("/mother1", (e[\degree]).asFloat ); },
|
||||
\rotation, Pfunc { |e| n.sendMsg("/rotation1", (e[\octave]).asFloat );
|
||||
postln(e[\degree]);
|
||||
postln(e[\octave]);
|
||||
|
||||
},
|
||||
);
|
||||
|
||||
|
||||
Pbindef(\m_2, \root, 4, \scale,~s2, \degree, ~bassroot16, \octave, 3, \dur,~rb,
|
||||
\p5, Pfunc { |e| n.sendMsg("/mother2", (e[\degree]).asFloat ); },
|
||||
\rotation, Pfunc { |e| n.sendMsg("/rotation2", (e[\octave]).asFloat ); },
|
||||
);
|
||||
|
||||
|
||||
/// try
|
||||
var a, b, r ,t, q , w;
|
||||
|
||||
a = Pbind(\type, \midi, \midicmd, \noteOn, \midiout, ~m32_2,
|
||||
\root, 4, \scale,~s2, \degree, ~bassroot16, \octave, ~o1, \dur,~rb,
|
||||
\p5, Pfunc { |e| n.sendMsg("/mother2", (e[\degree]).asFloat ); },
|
||||
\rotation, Pfunc { |e| n.sendMsg("/rotation1", (e[\octave]).asFloat );
|
||||
postln(e[\degree], e[\octave]);
|
||||
},
|
||||
);
|
||||
|
||||
b = Pbind( \type, \midi, \midicmd, \noteOn, \midiout, ~m32_2,
|
||||
\root, 4, \scale,~s2, \degree, ~dseq, \octave, ~o3, \dur,~rb,
|
||||
\p5, Pfunc { |e| n.sendMsg("/mother2", (e[\degree]).asFloat ); },
|
||||
\rotation, Pfunc { |e| n.sendMsg("/rotation1", (e[\octave]).asFloat );
|
||||
postln(e[\degree], e[\octave]);
|
||||
},
|
||||
);
|
||||
|
||||
q = Pbind(\type, \midi, \midicmd, \noteOn, \midiout, ~m32_1,
|
||||
\root, 4, \scale,~s2, \degree, ~bassroot16, \octave, ~o1, \dur,~rb,
|
||||
\p5, Pfunc { |e| n.sendMsg("/mother2", (e[\degree]).asFloat ); },
|
||||
\rotation, Pfunc { |e| n.sendMsg("/rotation1", (e[\octave]).asFloat );
|
||||
postln(e[\degree], e[\octave]);
|
||||
},
|
||||
);
|
||||
|
||||
w = Pbind( \type, \midi, \midicmd, \noteOn, \midiout, ~m32_1,
|
||||
\root, 4, \scale,~s2, \degree, ~dseq, \octave, ~o3, \dur,~rb,
|
||||
\p5, Pfunc { |e| n.sendMsg("/mother2", (e[\degree]).asFloat ); },
|
||||
\rotation, Pfunc { |e| n.sendMsg("/rotation1", (e[\octave]).asFloat );
|
||||
postln(e[\degree], e[\octave]);
|
||||
},
|
||||
);
|
||||
|
||||
r = Pseq( [a,b,a,b], 1);
|
||||
t = Pseq( [w,q,w,q], 1);
|
||||
|
||||
z = Ppar( [r,t], inf ).play;
|
||||
|
||||
z.stop;
|
||||
z.start;
|
||||
z.pause;
|
||||
z.resume;
|
||||
|
||||
|
||||
///
|
||||
|
||||
Pbindef(\m_1, \degree, ~dseq);
|
||||
Pbindef(\m_2, \degree, ~dseq);
|
||||
Pbindef(\m_2, \degree, ~bassroot16);
|
||||
Pbindef(\m_1, \octave, 3);
|
||||
Pbindef(\m_1, \octave, ~o3);
|
||||
|
||||
Pbindef(\m_1, \scale, ~s0);
|
||||
Pbindef(\m_2, \scale, ~s0);
|
||||
|
||||
Pbindef(\m_2, \octave, ~o1);
|
||||
Pbindef(\m_2, \octave, ~o2);
|
||||
Pbindef(\m_2, \octave, ~o1);
|
||||
|
||||
|
||||
// CC Control Message 1 ---> TOP Mother32 ASSIGN OUT
|
||||
( Pdef(\m_1_CC, Pbind( \type, \midi, \midicmd, \control, \midiout, ~m32_1,
|
||||
|
@ -93,6 +176,7 @@ Pbindef(\m_2, \root, 4, \scale,~s0,\degree, ~bassroot16,\octave, ~o1, \dur, ~rb
|
|||
// CC Control Message 1 ---> BOTTOM Mother32 ASSIGN OUT
|
||||
Pdef(\m_2_CC, Pbind( \type, \midi, \midicmd, \control, \midiout, ~m32_2, \ctlNum, 1, \control, Pexprand(77,127, inf), \dur, 1/8 )).play(quant:4);
|
||||
|
||||
|
||||
Pdef(\m_1).play(quant: 4); // TOP MOTHER
|
||||
Pdef(\m_2).play(quant: 4); // BTM MOTHER NOTEON
|
||||
|
||||
|
|
Loading…
Reference in New Issue