[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Why is midiInstrument a Staff property
From: |
Mats Bengtsson |
Subject: |
Re: Why is midiInstrument a Staff property |
Date: |
Sat, 03 Mar 2001 17:08:23 +0100 |
> Bernd Warken <address@hidden> writes:
>
> > > If you want different instruments for two voicess, you must put them
> > > on different staffs, ie, you probably need a dedicated midi score
> > > definition:
> >
> > That is very bad. So you are forced to write different source files
> > for graphical and midi output.
>
> No, in these cases you need just a dedicated midi score block, see my
> previous message.
Why not exploit the flexibility of Lilypond. Just add
the following lines in your file and you'll get a separate
instrument for each Voice:
(the original definitions can be found in ly/performer.ly)
\midi{
\translator{
% \type "Staff_performer";
\type "Performer_group_performer";
\name Staff;
\accepts Voice;
\consists "Key_performer";
\consists "Tempo_performer";
\consists "Time_signature_performer";
dynamicStyle = #"dynamic"
}
\translator{
% \type "Performer_group_performer";
\type "Staff_performer";
\name Voice;
% All notes fall to Grace if you leave Thread out (huh?)
\consists "Dynamic_performer";
\consists "Span_dynamic_performer";
\consists "Piano_pedal_performer";
\consists "Grace_position_performer";
\accepts Thread;
\accepts Grace;
}
}
One disadvantage of changing current default is that there's
a limited number of channels available in MIDI, so you don't
want to waste separate channels on each divisi in a big
orchestral score.
/Mats