Status: Accepted
Owner: [email protected]
Labels: Type-Documentation

New issue 3823 by [email protected]: Add @KNOWNISSUE for midiInstrument appear twice in MIDI output
http://code.google.com/p/lilypond/issues/detail?id=3823


[email protected] wrote:
\score {
   \new Staff {
     \set Staff.midiInstrument = #"electric bass (finger)" % 34
     \set Staff.midiPanPosition = #0
     a'1
   }
   \midi { }
}

         ['patch_change', 0, 0, 33],
         ['control_change', 0, 0, 10, 64],
         ['control_change', 0, 0, 42, 0],
         ['patch_change', 0, 0, 33],
         ['instrument_name', 0, 'electric bass (finger)'],
         ['control_change', 0, 0, 10, 64],
         ['control_change', 0, 0, 42, 0],
         ['control_change', 0, 0, 7, 100],

  As seen by the output, patch_change and control messages for panning
(10 is pan MSB, 42 is LSB pan) are done twice.

On 19/01/14 00:45, Devon Schudy wrote:

This is because a quirk of ordering makes Staff_performer treat these
properties as both changes and preexisting settings.
Staff_performer::acknowledge_audio_element creates the Audio_staff as
needed to perform Audio_items, and in this case the first Audio_item
is the patch change. This happens during do_announces, after the
context properties have already changed, so the Audio_staff starts
with extra control messages to set its initial state to match the
properties. Immediately afterwards, the control changes are performed.
The first copy of each change is the initial setting; the second is
the explicit change.

This happens only when properties change at the beginning of an
Audio_staff (which is not rare). I don't see a simple way to fix it,
but fortunately it's harmless.

James wrote:
is this worth an @KNOWNISSUE in the midi section?

I suppose so. "Changes to @code{midiInstrument} and other MIDI options
at the beginning of a staff sometimes appear twice in MIDI output."?


--
You received this message because this project is configured to send all issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

Reply via email to