Csound Csound-dev Csound-tekno Search About

Re: Midictrl vs. Ctrl7

Date2005-10-23 18:05
From"Art Hunkins"
SubjectRe: Midictrl vs. Ctrl7
I would expect channel assignment to work exactly like MIDI-triggered notes
that lack an assignment: channel 1 is assigned to instrument 1, 2 to 2,
etc., unless otherwise specified by massign.

Lacking documentation to the contrary, my expectation would be that the only
difference between midictrl and ctrl7 is that in ctrl7 the channel number is
made explicit. Clearly this is not currently the case.

The options seem to be: make the two the same except for the explicit
channel number (this should not break anything); clarify the documentation.

Of course, an underlying issue is whether or not there should be different
opcodes, or different assumptions, for midi-triggered notes and
score-triggered notes. Controllers are used in both contexts, and the
schedule and event opcodes bridge this gap. In all cases, a channel
assignment must somehow be arrived at. As a result, I'd think as much
clarity and consistency of usage as possible to be desirable.

Art Hunkins

----- Original Message -----
From: "Istvan Varga" 
To: 
Sent: Sunday, October 23, 2005 5:16 AM
Subject: Re: [Csnd] Midictrl vs. Ctrl7


> Well, from the syntax of midictrl it should be obvious that it is
> not suitable for use from score notes, as it does not take a channel
> number argument; which channel would you expect it to read in a non-MIDI
> triggered note ?
> Nevertheless, updating the manual may be useful just to make this clear.
>
> Art Hunkins wrote:
>
> > Looking over your Tutorial 3, I was struck by your use of midictrl. I
had
> > thought that, for me, midictrl didn't work; as a result I always used
ctrl7,
> > which *did* work.
> >
> > But in your examples midictrl worked fine. So I thought I'd dig deeper.
> >
> > What I found is something you (and the listserv, to which I'm copying
this)
> > may find interesting.
> >
> > As the two simplified .csd's - both based on your Tutorial 3 -
illustrate,
> > midictrl works only when notes are externally triggered from midi. OTOH,
> > ctrl7 works when either notes are triggered via midi *or* by a score
event
> > (as in an "always on" note such as is typical usage in my compositions).
> >
> > Simple modifications of the attached .csd's illustrate this. (A basic
midi
> > keyboard is required; note volume is controlled by modulation wheel -
> > controller 1.) Note that if you substitute midictrl for ctrl7 in
BohnCtrl7,
> > you don't get any sound, as kmod (midictrl) is now inactive.
> >
> > FWIW, I believe Csound documentation should reflect this difference,
> > especially the limitation on midictrl. I'm not aware that this important
> > distinction is made anywhere.
> >
> > Once again, congratulations on a fine set of tutorials - and I hope your
> > upcoming presentation goes well.
> --
> Send bugs reports to this list.
> To unsubscribe, send email to csound-unsubscribe@lists.bath.ac.uk

Date2005-10-23 20:54
FromIstvan Varga
SubjectRe: Midictrl vs. Ctrl7
Art Hunkins wrote:

> I would expect channel assignment to work exactly like MIDI-triggered notes
> that lack an assignment: channel 1 is assigned to instrument 1, 2 to 2,
> etc., unless otherwise specified by massign.

This is an interesting idea, but unfortunately it is by no means
guaranteed that there is an unambiguous mapping from instrument number
to MIDI channel, even if there is one the other way. For example,
you may have only a single instr 1 and control changes arriving on
all the 16 MIDI channels, or a single instrument assigned to multiple
MIDI channels with massign; in these cases, which MIDI channel do you
expect to be used by midictrl ?
Anyway, I will add a note to the manual that this opcode only works
in MIDI triggered notes.