Lilypond musicxml2ly Regression Tests
‘AAA-intro-regression.ly’
This document presents proofs for the musicxml2ly script provided with LilyPond 2.11.64. The files don’t have a description yet, so there is no official indication when the output is wrong. These snippets are provided as unit test files in MusicXML, converted to a .ly file by musicxml2ly and then processed by lilypond as usual.
If something does not seem wright in the output, it might either be that this feature has not been implemented yet, has been wrongly implemented, or a regression has crept in recently... This document is intended for finding bugs and for documenting bugfixes.
In the web version of this document, you can click on the file name or figure for each example to see the corresponding .ly intermediary file.
TODO: Find a way to add a description to the .ly files for texinfo.
The files are categorized by their first two digits with the following meaning:
- 00 ... Basics: Pitches, durations, rests, clefs, keys, time sigs, ties, etc.
- 01 ... Chords
- 02 ... MusicXML notations and articulations (articulations, ornaments, technicals, text markup)
- 03 ... MusicXML directions (dynamics; single symbols, not spanners like hairpins)
- 04 ... Spanners (hairpin, octave shift, trill, glissando, etc.)
- 05 ... Header information (title, composer, poet, etc.)
- 06 ... Lyrics
- 08 ... Multiple parts (staves)
- 09 ... Measure issues: Repeats, barlines, pickup measures, mid-measure barlines/repeats
- 10 ... Multiple voices per staff
- 12 ... Triplets, Tuplets
- 13 ... Grace notes
- 14 ... Multi-staff parts (one voice on multiple staves, e.g. PianoStaff)
- 15 ... Percussion
- 17 ... Guitar notation: Chord names, Fretboards, Tablature notation
- 18 ... Figured bass
- 19 ... Page layout: font/paper size, margins, spacing
- 20 ... Compressed MusicXML files
- 99 ... Compatibility modes with broken MusicXML exporters (i.e. ignore beams for Sibelius 5)
‘00-Basics.ly’
1. Basics (pitches, durations, ...)
‘00a-Basics-Pitches.ly’
All pitches from G to c”” in ascending steps; First without accidentals, then with a sharp and then with a flat accidental. Double alterations and cautionary accidentals are tested at the end.‘00b-Basics-Intervals.ly’
All pitch intervals in ascending jump size.‘00c-Basics-Durations.ly’
All note durations, from long, brevis, whole until 128th; First with their plain values, then dotted and finally doubly-dotted.‘00d-Basics-RestDurations.ly’
All different rest lengths: A two-bar multi-measure rest, a whole rest, a half, etc. until a 128th-rest; Then the same with dotted durations.‘00e-Basics-PitchedRests-PJB.ly’
Rests can have explicit pitches, where they are displayed. The first rest uses no explicit position and should use the default position, all others are explicitly positioned somewhere else.‘00f-Basics-Clefs.ly’
Various clefs: G, C, F, percussion, TAB and none; some are also possible with octavation and on other staff lines than their default (e.g. soprano/alto/tenor/bariton C clefs); Each measure shows a different clef (measure 17 has the "none" clef), only measure 18 has the same treble clef as measure 1.‘00g-Basics-Keys.ly’
Various key signature: from 11 flats to 11 sharps (each one first one measure in major, then one measure in minor)‘00h-Basics-TimeSignatures.ly’
Various time signatures: 2/2 (alla breve), 4/4 (C), 2/2, 3/2, 2/4, 3/4, 4/4, 5/4, 3/8, 6/8, 12/8‘00i-Basics-NoKeyOrClef.ly’
A score without any key or clef defined. The default (4/4 in treble clef) should be used.‘00j-Basics-NoTime-PJB.ly’
A score without a time signature (but with a key and clefs)‘00k-Basics-Backup.ly’
Two voices with a backup, that does not jump to the beginning for the measure for voice 2, but somewhere in the middle. Voice 2 thus won’t have any notes or rests for the first beat of the measures.‘00l-Basics-MultiMeasureRests.ly’
Four multi-measure rests: 3 measures, 15 measures, 1 measure, and 12 measures.‘00l-Basics-Tie-PJB.ly’
Two simple tied whole notes‘00m-MultimeasureRests-TimeSignatures.ly’
Multi-Measure rests should always be converted into durations that are a multiple of the time signature.‘00n-NoVoiceElement.ly’
The <voice> element of notes is optional in MusicXML (although Dolet always writes it out). Here, there is one note with lyrics, but without a voice assigned. It should still be correctly converted.‘00o-Basics-Modes.ly’
All different modes: major, minor, ionian, dorian, phrygian, lydian, mixolydian, aeolian, and locrian; All modes are given with 2 sharps.‘01-Chords.ly’
2. Chorded notes
‘01a-Chord-Basic.ly’
One simple chord consisting of two notes.‘01b-Chords-TwoNotes.ly’
Some subsequent (identical) two-note chords.‘01c-Chords-ThreeNotesDuration.ly’
Some three-note chords, with various durations.‘01d-Chords-SchubertStabatMater.ly’
Chords in the second measure, after several ornaments in the first measure and a p at the beginning of the second measure.‘01e-Chords-PickupMeasures.ly’
Check for proper chord detection after a pickup measure (i.e. the first beat of the measure is not aligned with multiples of the time signature!‘01f-Chord-ElementInBetween.ly’
Between the individual notes of a chord there can be direction or harmony elements, which should be properly assigned to the chord (or the position of the chord).‘02-Notations-Articulations.ly’
3. Notations and Articulations
‘02a-Notations-MusicXML.ly’
All <notation> elements defined in MusicXML. The lyrics show the notation assigned to each note.‘02b-Articulations-Texts-PJB.ly’
Text markup: different font sizes, weights and colors.‘02c-MultipleNotationChildren-RFK.ly’
It should not make any difference whether two articulations are given inside two different notation elements, inside two different articulations children of the same notation element or inside the same articulations element. Thus, all three notes should have a staccato and an accent.
‘02d-Arpeggio.ly’
Different Arpeggio directions (normal, up, down, non-arpeggiate)‘03-Directions.ly’
4. Dynamics and other single symbols
‘03a-Directions-MusicXML.ly’
All <direction> elements defined in MusicXML. The lyrics for each note describes the direction element assigned to that note.‘03b-AccordionRegistrations-MusicXML.ly’
All possible accordion registrations.‘03c-MetronomeMarks.ly’
Tempo Markings: note=bpm, text (note=bpm), note=note, (note=note), (note=bpm)‘04-Spanners.ly’
5. Spanners
‘04a-Spanners-Finale.ly’
Several spanners defined in MusicXML‘04b-Glissando.ly’
All different types of glissando defined in MusicXML‘04c-Spanners-Noteedit.ly’
Some spanners, exported by NoteEdit‘04d-Spanners-JScore.ly’
Some spanners, exported by JMSL’s MusicXMLWriter‘04e-OctaveShifts-Finale.ly’
All types of octave shifts (15ma, 15mb, 8va, 8vb)‘04f-Slurs.ly’
A note can be the end of one slur and the start of a new slur. Also, in MusicXML, nested slurs are possible like in the second measure where one slur goes over all four notes, and another slur goes from the second to the third note.‘04g-Trill-EndingOnGraceNote-Finale.ly’
A trill spanner that ends on an after-grace note.‘04h-Slur-ChordedNotes.ly’
‘05-Header.ly’
6. Header information
‘05a-HeaderQuotes-Finale.ly’
Several header fields and part names can contain quotes ("). This test checks whether they are converted/imported without problems (i.e. whether they are correctly escaped when converting).‘05b-MultipleRights.ly’
There can be multiple <rights> tags in the identification element of the score. The conversion shall still work, ideally using both of them.‘06-Lyrics.ly’
7. Lyrics
‘06a-Lyrics-Finale.ly’
Some notes with simple lyrics: Syllables, notes without a syllable, syllable spanners.‘06b-MultipleLyrics-Finale.ly’
Multiple (simple) lyrics. The order of the exported stanzas is relevant (identified by the number attribute in this test case)‘06c-Lyrics-Pianostaff-Finale.ly’
Lyrics assigned to the voices of a piano staff containing two simple staves. Each staff is assigned exactly one lyrics line.‘06d-Lyrics-Melisma-Finale.ly’
How to treat lyrics and slurred notes. Normally, a slurred group of notes is assigned only one lyrics syllable.‘06e-Lyrics-Chords-Finale.ly’
Assigning lyrics to chorded notes.‘06f-Lyrics-GracedNotes-Finale.ly’
Grace notes shall not mess up the lyrics, and they shall not be assigned a syllable.‘06g-Lyrics-NameNumber.ly’
A lyrics syllable can have both a number and a name attribute. The question is: What should be used to put syllables of the same voice together. This example uses different number/name combinations to check how different applications handle this unspecified case (The advice on the MusicXML mailing list was "there is no correct way, each application can do what it thinks is best").‘06h-Lyrics-BeamsMelismata.ly’
Beaming or slurs can indicate melismata for lyrics. Also make sure that notes without an explicit syllable are treated as if they were part of a melisma.‘08-Multiple-Parts.ly’
8. Multiple parts (staves)
‘08a-Partorder-Rosegarden.ly’
A piece with four parts. Are they converted in the correct order?‘08b-StaffGroups-Finale.ly’
A huge orchestra score with 28 parts and different kinds of nested bracketed groups. Each part/group is assigned a name and an abbreviation to be shown before the staff. Also, most of the groups show unbroken barlines, while the barlines are broken between the groups.‘08c-More-than-10-parts-Rosegarden.ly’
A piece with more than 10 parts to check whether the parts are correctly sorted.‘08d-NestedPartsBrackets-Finale.ly’
Two properly nested part groups: One group (with a square bracket) goes from staff 2 to 4) and another group (with a curly bracket) goes from staff 3 to 4.‘08e-LinebrokenInstrumentNames-Finale.ly’
Part names and abbreviations can contain line breaks.‘08f-PianoStaff-PJB.ly’
A simple piano staff‘08g-OverlappingPartGroups-Finale.ly’
MusicXML allows for overlapping part-groups, while many applications do not allow overlapping groups, but require them to be properly nested. In this case, one group (with a square bracket) goes from staff 2 to 4) and another group (with a curly bracket) goes from staff 3 to 5.‘09-Measures.ly’
9. Measures, Barlines, Repeats
‘09a-SimpleRepeat-Finale.ly’
A simple, repeated measure (repeated 5 times)‘09b-RepeatWithAlternatives-Finale.ly’
A simple repeat with two alternative endings (volta brackets).‘09c-Barlines-Finale.ly’
Different types of (non-repeat) barlines.‘09d-RepeatMultipleTimes-Finale.ly’
Repeats can also be nested.‘09e-Alternatives-Finale.ly’
Nested repeats, each with alternative endings.‘09f-Repeats-Finale.ly’
Some more nested repeats with alternatives. The barline between measure 7 and 8 will probably be messed up! (Should be a repeat on both sides!)‘09g-Endings-Finale.ly’
Some more nested repeats with alternatives, where the MusicXML file does not make sense in the first place. How well are applications able to cope with improper repeats and alternatives?‘09h-RepeatsNoEndBar-Finale.ly’
A forward-repeating bar line without an ending repeat bar.‘09i-MidmeasureBarline.ly’
Barlines can appear at mid-measure positions!‘09j-Midmeasure-Clef-Finale.ly’
A clef change in the middle of a measure‘09k-Upbeats-ImplicitMeasures-Finale.ly’
A 3/8 pickup measure, a measure that is split into one (incomplete, only 2/4) measure and an implicit measure, and an incomplete measure (containg 3/4).‘09l-PickupMeasure-SecondVoiceMessup.ly’
Voice 2 should start at 2nd beat of first full measure.‘09m-MultiVoice-MidMeasureClefChange-Finale.ly’
A multi-voice / multi-staff part with a clef change in the middle of a measure and a <backward> for voice 2 jumping back beyond that clef change.‘10-Multiple-Voices.ly’
10. Multiple voices per staff
‘10a-TwoVoicesOnStaff-Finale.ly’
Two voices share one staff. Each voice is assigned some lyrics.‘12-Tuplets.ly’
11. Triplets, Tuplets
‘12a-TripletsDuration-NoBracket-PJB.ly’
Some "triplets" on the end of the first and in the second staff, using only <time-modification>, but not explicit tuplet bracket. Thus, the duration of the notes in the second staff should be scaled properly in comparison to staff 1, but no visual indication about the tuplets is given.‘12b-Tuplets-Finale.ly’
Some tuplets (3:2, 3:2, 3:2, 4:2, 4:1, 7:3, 6:2) with the default tuplet bracket displaying the number of actual notes played.‘13-Grace-Notes.ly’
12. Grace notes
‘13a-GraceNotes-Finale.ly’
Different kinds of grace notes: acciaccatura, appoggiatura; beamed grace notes; grace notes with accidentals; different durations of the grace notes.‘13b-ChordAsGraceNote-Finale.ly’
Chords as grace notes.‘13c-GraceNote-MeasureEnd-Finale.ly’
A grace note that appears at the measure end (without any steal-from-* attribute set). Some applications need to convert this into an after-grace.‘13d-AfterGrace.ly’
Some grace notes and after-graces (indicated by steal-time-previous and steal-time-next).‘14-Multi-Staff-Parts.ly’
13. One voice on multiple staves
‘14a-MultistaffClefDynamics-Finale.ly’
A piano staff with dynamics and clef changes, that apply only to one voice or one staff, respectively.‘14b-DifferentKeys-PJB.ly’
A piano staff with different keys and clefs for each of its staves. The keys and clefs for both staves are given at the very beginning of the measure.‘14b-DifferentKeysAfterBackup-PJB.ly’
A piano staff with different keys and clefs for each of its staves. The key and clef for the second staff is given only after a backward, just before the first note of the second staff is given, but after the whole measure for staff 1 has been given.‘14c-StaffChange-Finale.ly’
Staff changes in a piano staff. The voice from the second staff has some notes/chords on the first staff. The final two chords have some notes on the first, some on the second staff.‘15-Percussion.ly’
14. Percussion
‘15a-Percussion-Finale.ly’
Three types of percussion staves: A five-line staff with bass clef for Timpani, a five-line staff with percussion clef, and a one-line percussion staff with only unpitched notes.‘17-Guitar.ly’
15. Guitar notation
‘17a-Chords-Finale.ly’
A normal staff with several (complex) chord names displayed.‘17b-Fretboards-Finale.ly’
A staff with chord names and some fretboards shown. (In Finaly, only the fretboards were shown!!!)‘17c-ChordsFrets-Finale.ly’
A staff with chord names and some fretboards shown. The fretboards can have an arbitrary number of frets/strings, can start at an arbitrary fret and can even contain fingering information.‘17d-ChordsFretsOnMultistaff-Finale.ly’
Chords and fretboards assigned to the voices in a multi-voice, multi-staff part. There should be fret diagrams above each of the two staves.‘17e-TabStaves-Finale.ly’
Some tablature staves, with explicit fingering information and different string tunings given in the MusicXML file.‘17f-AllChordTypes.ly’
All chord types defined in MusicXML. The staff will only contain one c’ note (NO chord) for all of them, but the chord names should be properly printed.‘18-Figured-Bass.ly’
16. Figured bass
‘18a-FiguredBass.ly’
Some figured bass containing alterated figures, bracketed figures and slashed figures. The last note contains an empty <figured-bass> element, which is invalid MusicXML, to check how well applications cope with malformed files.Note that this file does not contain any extenders!
‘19-Page-Layout.ly’
17. Page layout
‘19a-PageLayout-PrintMusic.ly’
Several page layout settings: paper size, margins, system margins and distances, different fonts, etc.‘20-Compressed-MusicXML.ly’
18. Compressed MusicXML files
‘20a-Compressed-MusicXML.ly’
A compressed MusicXML file, containing a simple MusicXML score and the corresponding .pdf output for reference.‘99-Compatibility.ly’
19. Compatibility with broken MusicXML
‘99a-Sibelius5-IgnoreBeaming.ly’
Dolet 3 for Sibelius (5.1) did not print out any closing beam tags, only starting and continuing beam tags. For such files, one either needs to ignore all beaming information or close all beams‘99b-Lyrics-BeamsMelismata-IgnoreBeams.ly’
If we properly ignore all beaming information from the Dolet 3 for Sibelius export file, make sure that the lyrics syllables are still assigned to the correct notes.About This Document
This document was generated by Han-Wen Nienhuys on November 16, 2008 using texi2html 1.79.
The buttons in the navigation panels have the following meaning:
| Button | Name | Go to | From 1.2.3 go to |
|---|---|---|---|
| [] | |||
| [ << ] | FastBack | Beginning of this chapter or previous chapter | 1 |
| [] | |||
| [Top] | Top | Cover (top) of document | |
| [Contents] | Contents | Table of contents | |
| [Index] | Index | Index | |
| [ ? ] | About | About (help) | |
| [] | |||
| [ >> ] | FastForward | Next chapter | 2 |
| [] | |||
| [] | |||
| [ < ] | Back | Previous section in reading order | 1.2.2 |
| [] | |||
| [ Up ] | Up | Up section | 1.2 |
| [] | |||
| [ > ] | Forward | Next section in reading order | 1.2.4 |
where the Example assumes that the current position is at Subsubsection One-Two-Three of a document of the following structure:
- 1. Section One
- 1.1 Subsection One-One
- ...
- 1.2 Subsection One-Two
- 1.2.1 Subsubsection One-Two-One
- 1.2.2 Subsubsection One-Two-Two
- 1.2.3 Subsubsection One-Two-Three <== Current Position
- 1.2.4 Subsubsection One-Two-Four
- 1.3 Subsection One-Three
- ...
- 1.4 Subsection One-Four
- 1.1 Subsection One-One