Re: [LAU] live performance, midi program change from the keyboard

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Alessandro Preziosi <lsnpreziosi@...>
Cc: <linux-audio-user@...>
Date: Friday, February 11, 2011 - 8:51 am

--0016364d28b16cf28e049bfdced0
Content-Type: text/plain; charset=ISO-8859-1

On Thu, Feb 10, 2011 at 5:56 PM, Alessandro Preziosi
wrote:

> i need to do something relatively simple, but i cant figure out how to do

It probably is an overkill for your problem, but I did this small
supercollider program; basically it makes an Alsa midi client to which you
send program changes and it changes through jack connections created by
jack_snapshot. So to use it you would create a jack_snapshot for each
synth/set of connections, save them and put the in "files" variable

Hope it works since I haven't time to test it now and it's been a while
since I've used it... also I remember for some strange reason if I gave it
many program changes rapidly one after the other it would clog the cpu

ah yes, once you have supercollider installed you could simply run it from
command line with "sclang jack-switcher.sc"

HTH,
renato

jack-switcher.sc:
(
//var midichan, files = "jsfiles".getenv.split($ );
var midichan, files;
files = ["/home/renato/Audio/1.snp","/home/renato/Audio/2.snp"]; //these
have to be files obtained through "jack_snapshot save 1.snp"

//Starts MIDI client
MIDIClient.init;
MIDIIn.program = {arg src, chan, prog;

[src,chan,prog].postln;

("jack_snapshot restore
"++files[prog.min(files.size)]).unixCmd;
};

)

--0016364d28b16cf28e049bfdced0
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

On Thu, Feb 10, 2011 at 5:56 PM, Alessan=
dro Preziosi <lsnpreziosi@gmail.com> wrote:
i need to do something relatively simple, but i cant figure out how to do i=
t, or what software i need...basically i have to play a certain song w=
here i need to switch between different sounds (say, a piano at the beginni=
ng using qsyinth and then a synth created with zynaddsubfx). I want to be a=
ble to switch between one setup to the other quickly, possibly using the pr=
ogram change from my keyboard. How do i do that???

On my keyboard i can create different programs, each us=
ing different sounds (patches) and switch between them with the click of a =
button. I want to use that, but I want to generate the sounds with my compu=
ter.=A0

I think I need a way to 'map' midi channels to different progr=
ams or midi patches to specific programs (like, when i select piano on the =
keyboard (patch0, bank0) it uses qsynth, and when i select a synth it uses =
zynaddusbfx).

Any ideas?Thank you very much,Alessandro PreziosiIt probably is an overkill for yo=
ur problem, but I did this small supercollider program; basically it makes =
an Alsa midi client to which you send program changes and it changes throug=
h jack connections created by jack_snapshot. So to use it you would create =
a jack_snapshot for each synth/set of connections, save them and put the in=
"files" variable
Hope it works since I haven't time to test it now and i=
t's been a while since I've used it... also I remember for some str=
ange reason if I gave it many program changes rapidly one after the other i=
t would clog the cpu
ah yes, once you have supercollider installed you could simply run it f=
rom command line with "sclang jack=
-switcher.sc
"HTH,renatojack-switcher.sc:
(//var midichan, files =3D "jsfiles".getenv.split($ );var=
midichan, files;files =3D ["/home/renato/Audio/1.snp","=
/home/renato/Audio/2.snp"]; //these have to be files obtained through =
"jack_snapshot save 1.snp"
//Starts MIDI clientMIDIClient.init;MIDIIn.program =3D {arg src=
, chan, prog; =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 =A0=A0=
=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 [src,chan,prog].postln;=A0=A0=
=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=
=A0=A0=A0=A0=A0 ("jack_snapshot restore "++files[prog.min(files.s=
ize)]).unixCmd;
=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 };)

--0016364d28b16cf28e049bfdced0--

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[LAU] live performance, midi program change from the keyboard, Alessandro Preziosi, (Thu Feb 10, 4:56 pm)
Re: [LAU] live performance, midi program change from the key..., Renato Budinich, (Fri Feb 11, 8:51 am)