lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: percussion & midi ?


From: Mats Bengtsson
Subject: Re: percussion & midi ?
Date: Tue, 14 Nov 2006 09:13:05 +0100
User-agent: Thunderbird 1.5.0.7 (X11/20060909)

It looks as if you have found a bug, indeed. If I try the following modified version of your example, it produces its output on channel 10 with LilyPond version 2.8 but on channel 2 with LilyPond version 2.10. The bug is in lily/performance.cc,
where a test
if (s->channel_ < 0)
was removed, which means that the explicit setting of channel_ = 9 in
lily/staff-performer.cc is lost.

\version "2.10.0"

\score {

   \new DrumStaff <<
      \drummode {
        bd4 sn4 bd4 sn4
        <<
{\voiceOne \repeat unfold 16 hh16 } \new DrumVoice { \voiceTwo bd4 sn4 bd4 sn4 }
        >> \oneVoice
      }
    >>
    \layout {}
    \midi {}
} %end lilypond

However, Simon, there was a problem with your input file as well.
The <<{...} // {...} >> feature is hard coded to provide ordinary Voice
contexts, so it will not give you the desired DrumVoice contexts. I'm actually
surprised that you get any reasonable printed output. Clearly, there is no
corresponding MIDI output. By explicitly instantiating the DrumVoice
contexts above, I solved that problem.

Regards

  /Mats
Simon Dahlbacka wrote:


On 11/13/06, *Mats Bengtsson* <address@hidden <mailto:address@hidden>> wrote:

    As long as you use a DrumVoice context to typeset the percussion, the
    MIDI output should automatically contain the corresponding drum sounds
    in channel 10.

       /Mats


In that case, something else is broken. I
ncluded is a snippet from 7.4.3 Percussion staves in the 2.10 manual (wrapped into a \score block)

%begin lilypond
\version "2.10.0"

\score {

    \new DrumStaff <<
       \new DrumVoice = "1" { s1 *2 }
       \new DrumVoice = "2" { s1 *2 }
       \drummode {
         bd4 sn4 bd4 sn4
         <<
           { \repeat unfold 16 hh16 }
           \\
           { bd4 sn4 bd4 sn4 }
         >>
       }
     >>
     \layout {}
     \midi {}
} %end lilypond


The produced midi does *not* sound like drums... (apart from only the first four notes audible...)

/Simon

--
=============================================
        Mats Bengtsson
        Signal Processing
        Signals, Sensors and Systems
        Royal Institute of Technology
        SE-100 44  STOCKHOLM
        Sweden
        Phone: (+46) 8 790 8463                         
       Fax:   (+46) 8 790 7260
        Email: address@hidden
        WWW: http://www.s3.kth.se/~mabe
=============================================





reply via email to

[Prev in Thread] Current Thread [Next in Thread]