Permalink
Browse files

experimental midi keyboard support, initial commit

Signed-off-by: Stefan Nussbaumer <st9fan@gmail.com>
  • Loading branch information...
nuss committed Aug 1, 2018
1 parent 38a7cbd commit 4ac351aeddeaf5e819c64d67fb13fb45ef9bc6b3
Showing with 28 additions and 0 deletions.
  1. +28 −0 CVCenter/extCVCenterMIDI.sc
@@ -0,0 +1,28 @@
+CVCenter {
*midiKeyboardGated { |synthDef = \default, specs, tab, server|
var testSynth;
server ?? { server = Server.default };
if (server.serverRunning.not) {
Error(
"The server '%' must already be running when invoking CVCenter:*midiKeyboard".format(server)
).throw;
};
SynthDescLib.at(synthDef) ?? {
Error(
"The SynthDef '%' does not exist".format(synthDef)
).throw;
};
if (SynthDescLib.at(synthDef).hasGate.not) {
Error(
"The given SynthDef does not provide a 'gate' argument and can not be used."
).throw;
}
testSynth = Synth(synthDef, [\amp, 0]);
}
}

0 comments on commit 4ac351a

Please sign in to comment.