From 4eeb05392c274c312ec408127b30ed1c3fe520e9 Mon Sep 17 00:00:00 2001 From: Nova deViator Date: Thu, 10 Sep 2015 17:29:45 +0200 Subject: [PATCH] connected RNS to SC to PROCESSING. nice. --- pde/IF3Si/IF3Si.pde | 29 +++++++++++++++++++++++-- rnx/IF3Si.xrns | Bin 4560 -> 5958 bytes scd/IF3Si.scd | 51 ++++++++++++++++++++++++++++++++++++++++++++ scd/snd_lines.scd | 11 +++++----- 4 files changed, 84 insertions(+), 7 deletions(-) diff --git a/pde/IF3Si/IF3Si.pde b/pde/IF3Si/IF3Si.pde index 270b300..72bb34e 100644 --- a/pde/IF3Si/IF3Si.pde +++ b/pde/IF3Si/IF3Si.pde @@ -52,7 +52,7 @@ float[] multXZ; PGraphics sphere; - +int tilesOverlap; void setup() { // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -111,6 +111,31 @@ void setup() { // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - } + +// process OSC messages +public void ctlin(int cc, int val) { // - - - - - - - - - - - - - - - - - - - - - - - + + // debug + println("## OSC: /ctlin cc:" + cc + " value:" + val); + + if (cc == 2) { tilesOverlap = val; } + + /* // triggers are on controller number 0 + if (cc == 0) { + } + + if (cc == 2) { flySpeedXfactor = (val - 64); } // speed (&direction) on X axis [-1 - 1] FIXit! + if (cc == 3) { flySpeedYfactor = (val - 64); } // speed (&direction) on Y axis [-1 - 1] FIXit! + */ + +} + + + + + + + void draw() { // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - // clean screen ````````````````````````````````````````````````````| @@ -197,7 +222,7 @@ void draw() { // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 0, // texture number/id 10, // texture speed X 1, // texture speed Y - 64 // overlap. 127 = 300% + tilesOverlap // overlap. 127 = 300% ); diff --git a/rnx/IF3Si.xrns b/rnx/IF3Si.xrns index 52d495ff38d0d5705d4a6eaf24756dc04022f132..c6a715129a03c5bae5098d17b62e5f8e7af262fb 100644 GIT binary pat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G6Eox@1K5MI$Xaz zofQ_!nYG+t!56m0_?&o~Y$lK20ld(}1JVNiyPtCVqucS|pZ)*bm4B=LTND0s{qL%f aTW{vymb}m;ApAQ6yq#{hr#98!=zjo2xBw^s diff --git a/scd/IF3Si.scd b/scd/IF3Si.scd index 3048c4d..f441e28 100644 --- a/scd/IF3Si.scd +++ b/scd/IF3Si.scd @@ -34,6 +34,57 @@ postln("\n\n Server.default.waitForBoot { + + + // midi init & stuff: + + + + + + +( +var p5osc; +var midiFunc; + + +//MIDIIn.connectAll; +p5osc = NetAddr.new("zarquon", 12000); + + +midiFunc = MIDIFunc.cc({ + + arg val1, val2; + postln("sending: /ctlin " + val2 + " " + val1); + // we need to send /ctlin CCnum CCvalue + p5osc.sendMsg("/ctlin", val2, val1); + + + +}, (0..127)); // match all cc (from 1..127) +) + +midiFunc.free; // cleanup +p5osc.disconnectAll + +MIDIIn.findPort; + + + +MIDIClient.init(1,0); +MIDIClient.sources; +MIDIIn.connect("Renoise MIDI Output", "out0"); + + + + + + + + + + + // where are we? var dir = PathName(thisProcess.nowExecutingPath).pathOnly; diff --git a/scd/snd_lines.scd b/scd/snd_lines.scd index 98969eb..f95c2e3 100644 --- a/scd/snd_lines.scd +++ b/scd/snd_lines.scd @@ -259,9 +259,11 @@ post(" "); ~mainTimeline = Routine({ + arg layer = 0; + var delta, playhead, frequency, amp, step=0, - nextdelta, nextplayhead, nextfrequency, nextamp, - frequency_alt, nextfrequency_alt, siLines; + nextdelta, nextplayhead, nextfrequency, nextamp, + frequency_alt, nextfrequency_alt, siLines; siLines = ~siLinesData; postln(siLines); @@ -270,12 +272,11 @@ post(" "); while { step < siLines.size; + layer == siLines[step] } { // exposition - //frequency = siLines[step][0].asFloat.linexp(3900, 7200, 16000, 40); frequency = siLines[step][4].asFloat; - // frequency_alt = siLines[step][0].asFloat.linexp(3900, 7200, 40, 16000); frequency_alt = siLines[step][5].asFloat; playhead = siLines[step][0].asFloat; nextfrequency = siLines[step+1][4].asFloat; @@ -293,7 +294,7 @@ post(" "); post("| "); post((playhead/60).round(1).asString.padLeft(2)); post(":"); - post((playhead%60).round(1).asString.padLeft(2); + post((playhead%60).round(1).asString.padLeft(2)); post(" | "); // post(siLines[step][2]); // post( "nm | " );