1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123
|
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="GENERATOR" CONTENT="Mozilla/4.03 [en] (X11; I; IRIX 6.3 IP32) [Netscape]">
<TITLE>CEC_midi</TITLE>
</HEAD>
<BODY>
<CENTER></CENTER>
<CENTER><IMG SRC="help.gif" ></CENTER>
<CENTER>
<H4>
<B><A HREF="index.html">HELP INDEX</A></B></H4></CENTER>
<CENTER>
<HR></CENTER>
<H4>
<U>NAME</U></H4>
<B>cmidi</B> - Creation of midi input control port.
<H4>
<U>SYNOPSIS</U></H4>
<PRE><B>cmidi</B> name ?options?</PRE>
<H4>
<U>OPTIONS</U></H4>
<TT><B>-label</B> <I>character string<BR>
</I></TT><I>
</I>will replace the name label besides or underneath the slider.<I> ;default
none</I>
<P><TT><B>-event</B> <I>pbend | touch | veloc | notnum
|ctrl[1-127]</I></TT><I> <BR>
</I>determines the rtype of midi event that will control the parameter
<I>;default notnum</I>
<BR><BR>
<TT><B>-channel</B> <I>1 to 16<BR>
</I></TT><I>
</I>the channel; number on which this event will arrive<BR>
<TT><B>-min</B> <I>int | float<BR>
</I></TT><I> </I>
determines the minimum value of the slider <I> ;default
0</I>
<BR><I> <BR>
</I><TT><B>-max</B> <I>int | float<BR>
</I></TT>
determines the maximum value of the slider <I> ;default
127</I>
<P><TT><B>-init</B> <I>int | float between min
and max<BR>
</I></TT><I>
</I>determines the initial value of the slider.<I> ;default
0 | -min</I>
<BR><I></I>
<H4>
<U>DESCRIPTION</U></H4>
The <B>cmidi</B> command creates an automatic Csound midi setup where the
value of a midi event is passed on to the orchestra via a global "gk[name]"
variable. The <B>cmidi</B> object varies from other Cecilia objects in
that it does not create an interface object except a "lag time" slider
that smoothes continuous midi input. The <B>cmidi</B> object is meant to
be used primarily as an interface to a JLCooper MidiFader unit but will
understand any kind of midi channel voice message. The values from the
midi events (0-127) will be scaled between <B>min</B> and <B>max </B>.
<P>When the orchestra and score are compiled, the <B>cmidi</B> object creates
its own instruments to preprocess midi information within Csound. This
is not normally seen by the user.
<P>Remember that a midi instrument must be launched with a midi note-on
message for it to transmit any data. Therefor, if a pitch bend message
is used to control a variable, the pitchbend data will be accepted <B>only</B>
if there is a currently active midi note. A good way to get around this
problem is to program the desired JLCooper fader to delivers midi note-on
messages. The user can then specify the velocity received as the data carrier.
This way, a note-on message will always be sent along with the desired
velocity data.
<P>A regular <B>cslider</B> is always produced along with a <B>cmidi</B>.
That slider is used to set a portamento or lag value for the midi data.
The portamento value is issued automatically at init time only.
<P>An option menu is also produced with the options: <B>practice, midi_record,
playback, load and save</B>. The user can record any midi event with <B>midi_record</B>
and replay them with <B>playback</B>. A given stream can be saved under
any name with <B>save</B> and recalled with <B>load</B>. <B>Practice</B>
allows to simply play the sliders without recording.
<P> <B>It is compulsory</B>, when using the <B>cmidi</B> object to
also declare a "total_time" <B>cslider</B>. <BR>
<BR>
<H4>
<U>EXAMPLE</U></H4>
The definition:
<PRE> <B>cmidi</B> pitch -ev veloc -ch 16 -min 0 -max 45 -init 10</PRE>
sets up a midi input stream that communicates with the orchestra through
the global variable <I>"gkpitch"</I> along with a <I>portamento</I>
slider named <I>lag-pitch</I>. Data will be read from the velocity value
of any note-on message received on channel 16. The data will be scaled,
on a base of 0 to 127 to the a value between 0 and 45. The value of <I>gkpitch</I>
is initialized at 10.
<P>The definition:
<PRE> <B>cec_midi</B> amp -ev ctrl38 -ch 16 -min .5 -max 10 -init 10</PRE>
sets up a midi input stream named <I>"gkamp"</I> along with a <I>portamento</I>
slider named <I>lag-amp</I>. Data will be read from the value of controller
#38 received on channel 16. <B>No data will be received</B> if there is
no currently active note on channel 16. A midi keyboard or another computer
can be used to send midi note-on events just before the controller data
is needed. <BR>
<BR>
<BR>
<BR>
<HR>
<BR>Copyright 1996 - 97
</BODY>
</HTML>
|