w3c / musicxml

MusicXML specification
518 stars 57 forks source link

MusicXML <instrument id=“BLAH”> not affecting MIDI or playback #425

Open ultraGentle opened 3 years ago

ultraGentle commented 3 years ago

At the top of a MusicXML file, I've defined MIDI instruments with IDs, Channel, and Program information as follows (see this w3.org page for a full example)

<midi-instrument id="Piano">
    <midi-channel>1</midi-channel>
    <midi-program>1</midi-program>
</midi-instrument>

<midi-instrument id="Harp">
    <midi-channel>2</midi-channel>
    <midi-program>2</midi-program>
</midi-instrument>

Then, later in the file, within a given <note> element, I've can inserted an <instrument id="PREVIOUSLY_DEFINED_ID"/> tag to switch to the defined MIDI channel and program.

However, when I create a file following the syntax above, and I open it in a MusicXML compatible program (e.g. Musescore, Reaper, Sibelius), the <instrument id="BLAH/> has no effect on the MIDI channel or program.

I am using a soundfont that does include channel and program information, so I don't think it's that. Furthermore, inspecting the MIDI data generated by converting or exporting the MusicXML file as MIDI shows no changes to the program or channel parameters.

I'm not sure whether this is a (1) syntax error on my part, (2) an interpretation error by the MusicXML readers (but I've tried multiple programs), or (3)...?

Thanks!

mdgood commented 3 years ago

@ultraGentle I apologize for the delay in replying to this. I suspect what is happening is that most applications are using the <instrument-sound> element within the <score-instrument> element to be guiding these kinds of playback changes. With VST and AU playback being so common now, the <midi-instrument> element and its child elements are less useful now than they were in MusicXML 1.0 days.

In the future it might be good for us to better document the state of the playback elements and improve our guidance for using these elements most effectively.

ultraGentle commented 3 years ago

OK, thanks for the heads up!